Semantic Web Services

Dieter Fensel (cid:2) Federico Michele Facca (cid:2)
Elena Simperl (cid:2) Ioan Toma

Semantic
Web Services

Prof. Dieter Fensel
Dr. Federico Michele Facca
Ioan Toma
STI Innsbruck, ICT-Technologiepark
University of Innsbruck
Technikerstr. 21a
6020 Innsbruck
Austria
dieter.fensel@sti2.at
federico.facca@sti2.at
ioan.toma@sti2.at

Dr. Elena Simperl
Institute AIFB, Building 11.40
Karlsruhe Institute of Technology
Englerstr. 11
76128 Karlsruhe
Germany
elena.simperl@kit.edu

ISBN 978-3-642-19192-3
DOI 10.1007/978-3-642-19193-0
Springer Heidelberg Dordrecht London New York

e-ISBN 978-3-642-19193-0

Library of Congress Control Number: 2011927266

ACM Computing Classiﬁcation (1998): H.3.5, D.2.12, I.2, J.1

© Springer-Verlag Berlin Heidelberg 2011
This work is subject to copyright. All rights are reserved, whether the whole or part of the material is
concerned, speciﬁcally the rights of translation, reprinting, reuse of illustrations, recitation, broadcasting,
reproduction on microﬁlm or in any other way, and storage in data banks. Duplication of this publication
or parts thereof is permitted only under the provisions of the German Copyright Law of September 9,
1965, in its current version, and permission for use must always be obtained from Springer. Violations
are liable to prosecution under the German Copyright Law.
The use of general descriptive names, registered names, trademarks, etc. in this publication does not
imply, even in the absence of a speciﬁc statement, that such names are exempt from the relevant protective
laws and regulations and therefore free for general use.

Cover design: deblik

Printed on acid-free paper

Springer is part of Springer Science+Business Media (www.springer.com)

Preface

All students interested in researching the Internet are living in very interesting and
exciting times. From the Internet’s beginning in the 1960s up to the present day,
the Internet has grown to become a vast platform where there are now 2 billion
users of this global infrastructure.1 Predictions are that this number will rise to over
4 billion with the advent of the Mobile Internet, providing access to the Internet via
mobile devices including mobile phones. We are also witnessing a number of other
trends which are driving the popular use of the Internet. Firstly, we have the Web,
which now contains over 1 trillion resources with over 10 million added each day.
At the end of 2009 alone, there were 234 million websites of which 47 million were
added in the year. Secondly, we have the Web 2.0 phenomenon where the focus is
on prosumers who play a dual role of consumer and producer. Enabling the general
community to create and publish online material has facilitated the creation of con-
tent at unprecedented rates. For example, the current upload to Flickr is equivalent
to 30 billion new photos per year and YouTube now serves over 1 billion videos per
day. A ﬁnal, general Internet phenomena, has been the rise of user generated appli-
cations on mobile devices as exempliﬁed by Apple’s iPhone and iPad Apps within
the iTunes Store. The combination of public interest and a relatively simple creation
and publishing process have resulted in over 200,000 Apps now being available for
the iPhone and iPad and have led to Apple’s share price surpassing Google’s. For a
researcher, especially in ICT, a great interest lies in making an impact on our present
world in some way. Whilst this impact is usually seen in the economic or commer-
cial arenas, it may also have important social implications. A particularly interesting
phenomenon which has emerged over the last century is the transition of the Global
Economy from the one based on manufacturing (and before that on agriculture)
to the one based on services, sometimes known as the third sector. As deﬁned in
Wikipedia, a service is the non-material equivalent of a good where the provision of
a service does not result in ownership which distinguishes a service from providing
physical goods. From small beginnings at the turn of the twentieth century, ser-
vices now dominate the Global Economy, accounting for 63% of the world’s Gross

1http://www.internetworldstats.com/stats.htm.

v

vi

Preface

Domestic Product at $37 trillion in 2009. In a fundamental respect, this textbook
examines the link between the above mentioned through the inclusion of two main
technologies: Web services and technologies associated with the Semantic Web. In a
technical sense, Web services are computational components which can be invoked
using standard Web protocols. More importantly, Web services can act as proxies for
business services that can be used to deliver some functionality for clients or users
which adds value. It is this second feature of Web services as online substitutes for
business services that has caused tremendous interest in the corporate sphere. Af-
ter initial interest, however, a number of problems emerged related to how online
services could be found, invoked and composed. Over the past decade Semantic
Web technology has been applied to address this through the delegation of certain
portions of the above tasks to automated or semi-automated systems. This textbook
examines the combination of Web services and the Semantic Web from a number of
core ingredients, exploring the fundamental essence of its constituents. In particu-
lar, the Web services and the Semantic Web are broken down into a set of underly-
ing principles and explained using simple examples. Connections to the real world
and industrial deployment are outlined using a number of non-trivial use cases and
through examination of the technologies supporting the commercial Web service
search company Seekda. An associated website at www.swsbook.org facilitates the
inclusion and use of additional learning material. More generally, this book beneﬁts
from research experiences gained in three large European projects: DIP, SUPER and
SOA4All which together have a combined budget of over 50 million euros. When
combined with the extensive research track record of the authors, it is difﬁcult to
think of a more useful intellectual source for ﬁnding out about the Semantic Web
Services area. If you are just embarking on a career as an ICT researcher, you are
interested in services and/or semantics, or if you simply wish to catch up on the lat-
est research in the Semantic Web area, then I thoroughly recommend that you read
this book.

Knowledge Media Institute, The Open University, UK
STI International, Austria

John Domingue

Contents

Part I

Scientiﬁc and Technological Foundations of Semantic Web

Services

1

Introduction .

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

2 Web Science .

.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.
.
.
2.1 Motivation .
.
.
.
2.2 Technical Solution . . . . . . . . . . . . . . . . . . . . . . . . . .
2.2.1 History of the Web . . . . . . . . . . . . . . . . . . . . . .
2.2.2 Building the Web . . . . . . . . . . . . . . . . . . . . . .
2.2.3 Web in Society .
.
.
.
.
2.2.4 Operationalizing the Web Science for a World

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

3

of International Commerce . . . . . . . . . . . . . . . . .
2.2.5 Analyzing the Web . . . . . . . . . . . . . . . . . . . . . .
2.3 Web 2.0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . .
2.4 Conclusions
. . . . . . . . . . . . . . . . . . . . . . . . . . . . .
References .

.
.

.
.

.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.

.
.
.
.
Service Science .
.
.
.
.
3.1 Motivation .
3.2 What Is a Service? .
.
.
.
3.3 Service Analysis, Design, Development and Testing . . . . . . . .
3.4 Service Orchestration, Composition and Delivery . . . . . . . . .
3.5 Service Innovation . . . . . . . . . . . . . . . . . . . . . . . . . .
3.6 Service Design Approach . . .
. . . . . . . . . . . . . . . . . . .
3.7 Service Pricing Method and Economics . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . .
3.8 Service Quality Measurement .
.
.
.
.
3.9 Service Technologies
.
3.10 Service Application .
.
.
.
.
.
. . . . . . . . . . . . . . . . . . . . . . . . . . . . .
3.11 Conclusions
. . . . . . . . . . . . . . . . . . . . . . . . . . . . .
References .

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

3

9
9
10
10
12
16

18
21
22
22
23

25
25
26
27
29
30
31
32
32
33
34
34
35

vii

viii

Contents

4 Web Services

.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

. .
.
.
.
.
.
.

.
4.1 Motivation .

.
.
.
.
.
.
4.1.1 Service Oriented Computing (SOC) .
.
4.1.2 Service Oriented Architecture (SOA) .

.
.
.
.
4.2 Technical Solution . . . . . . . . . . . . . . . . . . . . . . . . . .
4.2.1 Deﬁning Web Services . . . . . . . . . . . . . . . . . . . .
4.2.2 Web Service Technologies . . . . . . . . . . . . . . . . . .
4.3 Illustration by a Larger Example
. . . . . . . . . . . . . . . . . .
4.4 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
4.5 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . .

References .

.
.
.
.
. .
.
.

.
.
.
.

.
.
.
.

.

.

.

.

.

.

.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

5 Web2.0 and RESTful Services .
.

.
.
.
5.1 Motivation .
.
.
.
5.2 Technical Solution . . . . . . . . . . . . . . . . . . . . . . . . . .
5.2.1 REST . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
5.2.2 Describing RESTful Services . . . . . . . . . . . . . . . .
. . . . . . . . .
5.2.3 Data Exchange for RESTful Services . . .
5.2.4 AJAX APIs
. . . . . . . . . . . . . . . . . . . . . . . . .
5.2.5 Examples of RESTful Services . . . . . . . . . . . . . . .
5.3 Illustration by a Larger Example
. . . . . . . . . . . . . . . . . .
5.4 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
5.5 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . .

References .

37
37
38
39
40
41
42
55
56
60
64

67
67
68
69
69
72
77
78
80
83
84
85

6

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

87
.
.
.
.
Semantic Web .
87
6.1 Motivation .
.
.
.
89
6.2 Technical Solution . . . . . . . . . . . . . . . . . . . . . . . . . .
6.3 Extensions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
98
6.4 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101
6.5 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 102
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103

References .

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

Part II Web Service Modeling Ontology Approach

.

.

.

.

.

.

.

.

.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

7 Web Service Modeling Ontology .
.

. 107
.
7.1 Motivation .
. 107
.
7.2 Technical Solution . . . . . . . . . . . . . . . . . . . . . . . . . . 108
7.2.1 Ontologies . . . . . . . . . . . . . . . . . . . . . . . . . . 110
7.2.2 Web Services . . . . . . . . . . . . . . . . . . . . . . . . . 113
7.2.3 Goals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 116
. . . . . . . . . . . . . . . . . . . . . . . . . . 116
7.2.4 Mediators
7.3 Extensions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 118
. . . . . . . . . . . . . . . . . . 119
7.4 Illustration by a Larger Example
7.4.1 Ontologies . . . . . . . . . . . . . . . . . . . . . . . . . . 119
7.4.2 Goals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 120
7.4.3 Web Services . . . . . . . . . . . . . . . . . . . . . . . . . 120

Contents

ix

8

9

7.4.4 Mediators

. . . . . . . . . . . . . . . . . . . . . . . . . . 124
7.5 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124
7.6 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 128
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 129

References .

The Web Service Modeling Language . . . . . . . . . . . . . . . . . . 131
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 131
8.1 Motivation .
8.1.1 Principles of WSMO . . . . . . . . . . . . . . . . . . . . . 131
8.1.2 Logics Families and Semantic Web Services . . . . . . . . 132
8.2 Technical Solution . . . . . . . . . . . . . . . . . . . . . . . . . . 134
8.2.1 WSML Language Variants
. . . . . . . . . . . . . . . . . 134
8.2.2 WSML Basis . . . . . . . . . . . . . . . . . . . . . . . . . 136
8.2.3 Ontologies in WSML . . . . . . . . . . . . . . . . . . . . 139
8.2.4 Web Services in WSML . . . . . . . . . . . . . . . . . . . 145
8.2.5 Goals in WSML . . . . . . . . . . . . . . . . . . . . . . . 149
8.2.6 Mediators in WSML . . . . . . . . . . . . . . . . . . . . . 152
8.2.7 Technologies for Using WSML . . . . . . . . . . . . . . . 152
8.3 Extensions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 153
. . . . . . . . . . . . . . . . . . 155
8.4 Illustration by a Larger Example
8.4.1 Travel Ontology . . . . . . . . . . . . . . . . . . . . . . . 155
. . . . . . . . . . . . . . . . . . . . . . . . . . . 157
8.4.2 Services
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 157
8.4.3 Goal
8.5 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 158
8.6 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 158
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 160

References .

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

The Web Service Execution Environment
9.1 Motivation .

. . . . . . . . . . . . . . . 163
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163
9.1.1 Service Orientation . . . . . . . . . . . . . . . . . . . . . 164
. . . . 168
9.1.2 Execution Environment for Semantic Web Services
. 168
.
.
9.1.3 Governing Principles
.
9.2 Technical Solution . . . . . . . . . . . . . . . . . . . . . . . . . . 169
9.2.1 SESA Vision . . . . . . . . . . . . . . . . . . . . . . . . . 169
9.2.2 SESA Middleware . . . . . . . . . . . . . . . . . . . . . . 175
9.2.3 SESA Execution Semantics . . . . . . . . . . . . . . . . . 191
. . . . . . . . . . . . . . . . . . 200
9.3.1 Modeling of Business Services
. . . . . . . . . . . . . . . 202
9.3.2 Execution of Services . . . . . . . . . . . . . . . . . . . . 206
9.4 Possible Extensions . . . . . . . . . . . . . . . . . . . . . . . . . 210
. . . . . . . . . . . . . . . . . . . 210
9.5 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213
9.6 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 215

9.3 Illustration by a Larger Example

9.4.1 Goal Subscription . . .

References .

x

Contents

Part III Complementary Approaches for Web Service Modeling

Ontology

10 Triple Space Computing for Semantic Web Services

. . . . . . . . . 219
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 219
10.1 Motivation .
10.2 Technical Solution . . . . . . . . . . . . . . . . . . . . . . . . . . 221
10.2.1 Tuplespace Computing . . . . . . . . . . . . . . . . . . . 221
10.2.2 Triple Space Computing . . . . . . . . . . . . . . . . . . . 223
. . . . . . . . . . . . . . 224
10.2.3 Triple Space Conceptual Models
10.2.4 Triple Space Architecture . . . . . . . . . . . . . . . . . . 229
10.2.5 Triple Space and Semantic Web Services .
. . . . . . . . . 231
10.2.6 Triple Space and Semantic SOA . . . . . . . . . . . . . . . 238
. . . . . . . . . . . . . . . . . . 242
10.3 Illustration by a Larger Example
10.4 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 248

References .

.

.

.

.

.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.
.

.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.
. .
.
.

11 OWL-S and Other Approaches .
.
.
.

. 251
.
.
. 251
.
.
.
11.1 Motivation .
. 252
.
.
.
.
11.2 OWL-S .
.
11.2.1 Service Proﬁle .
. 252
.
.
11.2.2 Service Grounding . . . . . . . . . . . . . . . . . . . . . . 254
. 256
.
.
.
11.2.3 Service Model
11.2.4 An Extension to OWL-S .
. 259
.
.
11.2.5 Tool Support . . . . . . . . . . . . . . . . . . . . . . . . . 261
11.2.6 OWL-S Summary . . . . . . . . . . . . . . . . . . . . . . 263
11.3 METEOR-S . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 263
. . . . . . . . . 264
11.3.1 Semantic Annotation of Web services . . .
11.3.2 Semantics-Based Discovery of Web Services . . . . . . . . 267
11.3.3 Composition of Web Services . . . . . . . . . . . . . . . . 268
. . . . . . . . . . . . . . . . . . . 269
11.3.4 METEOR-S Summary .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 270
11.4.1 Discovery, Selection and Mediation . . . . . . . . . . . . . 273
11.4.2 Communication . . . . . . . . . . . . . . . . . . . . . . . 274
11.4.3 Choreography and Orchestration . . . . . . . . . . . . . . 275
11.5 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 276
11.6 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 277
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 277

11.4 IRS-III . . .

References .

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.
.

.
.

.
.

12 Lightweight Semantic Web Service Descriptions .
.
.

. 279
. 279
.
12.1 Motivation .
12.2 Technical Solution . . . . . . . . . . . . . . . . . . . . . . . . . . 280
12.2.1 SAWSDL . . . . . . . . . . . . . . . . . . . . . . . . . . 281
12.2.2 WSMO-Lite Service Semantics . . . . . . . . . . . . . . . 283
12.2.3 WSMO-Lite in SAWSDL . . . . . . . . . . . . . . . . . . 288
. . . . . . . . . . . . . 289
12.2.4 WSMO-Lite for RESTful Services
12.3 Extensions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292
12.4 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295

.
.
. .

.
.

.
.

.
.

.
.

.
.

.

Contents

xi

12.5 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295

References .

Part IV Real-World Adoption of Semantic Web Services

13 What Are SWS Good for? DIP, SUPER, and SOA4All Use Cases . . 299
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 299

13.1 Motivation .
13.2 Data, Information, and Process Integration with Semantic Web

Services (DIP) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 300
13.2.1 Motivation . . . . . . . . . . . . . . . . . . . . . . . . . . 300
13.2.2 Technical Solution . . .
. . . . . . . . . . . . . . . . . . . 301
. . . . . . . . . . . . . . . . . . . . . . . . . . 302
13.2.3 Use Cases

.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
.

.
Enterprises (SUPER)
13.3.1 Motivation .
.
13.3.2 Technical Solution . . .
13.3.3 Use Cases

13.3 Semantics Utilized for Process Management Within and Between
.
.
.
.

. 304
.
.
.
.
. 305
.
.
. . . . . . . . . . . . . . . . . . . 307
. . . . . . . . . . . . . . . . . . . . . . . . . . 311
. . . . . . . . . 311
13.4.1 Motivation . . . . . . . . . . . . . . . . . . . . . . . . . . 312
13.4.2 Technical Solution . . .
. . . . . . . . . . . . . . . . . . . 313
. . . . . . . . . . . . . . . . . . . . . . . . . . 318
13.4.3 Use Cases
13.5 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 323
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 323

13.4 Service Oriented Architectures for All (SOA4All)

References .

.
.

.
.

.
.

.
.

14 Seekda: The Business Point of View . . . . . . . . . . . . . . . . . . . 325
14.1 Motivation .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 325
14.2 Technical Solution . . . . . . . . . . . . . . . . . . . . . . . . . . 326
. . . . . . . . . . . . . . . . . . . . . . . . . . . 327
.
. 333
.
.
.
. . . . . . . . . . . . . 333
. . . . . . . . . . . . . . . . . . 342
14.3 Illustration by a Larger Example
14.4 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 349
14.5 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 351
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 351

14.2.1 Crawler
14.2.2 Search Engine .
.
14.2.3 Bundle Conﬁgurator and Assistant

References .

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 353

Part I
Scientiﬁc and Technological Foundations
of Semantic Web Services

Chapter 1
Introduction

“The Internet world as we know it today has undergone far-reaching and profound changes
since it has become a critical communications infrastructure underpinning our economic
performance and social welfare. With an estimate of 1.1 billion ﬁxed users and over 3 billion
mobile users world-wide already, the Internet of tomorrow is poised to become a fully
pervasive infrastructure providing anywhere, anytime broadband connectivity.”1

Interoperability has always been an important topic in Computer Science. We
began with the obscure ingredients of a simple network to exchange Morse code
and punch cards which enabled a semi-automatic loom. The recipe evolved into an
immensely powerful infrastructure that would serve as the basis of modern commu-
nication and collaboration. Several decades ago, the fundamental technologies that
would spawn the Internet as we know it were still in their infancy. The past 30 years
have brought these technologies to a mature level; communication, collaboration
and system interoperability now depend upon “killer applications” such as email
and the Mobile Web.

The ICT industry is witnessing a dramatic change, similar to the evolution of
more traditional industries in the last century. The development of ICT solutions
is now shifting from being a discipline mostly focussed upon productivity, to the
one aiming at providing end-to-end customized services able to meet customers’
demands and bring distinctiveness to the solutions provided. This evolution is, to a
large extent, due to the maturity which the ICT industry is reaching. Additionally,
current trends such as the diversiﬁcation of client hardware and communication in-
frastructure, the increasing availability of wireless and mobile access, as well as the
ICT/Mobile/Media convergence, demonstrate the changes of scale and dynamicity
that will be brought by the Future Internet and are furthermore making more evi-
dent the need to restructure the development and delivery chain to address future
challenges and opportunities.

Still, ensuring interoperability in open, heterogeneous, and dynamically chang-
ing environments, such as the Internet, remains a major challenge for actual
machine-to-machine integration. Applications are usually designed for a certain

1BLED Future Internet Manifesto, March 2008, available at http://www.ﬁ-bled.eu/.

D. Fensel et al., Semantic Web Services,
DOI 10.1007/978-3-642-19193-0_1, © Springer-Verlag Berlin Heidelberg 2011

3

4

1

Introduction

context; this context is then hardwired in terms of hidden assumptions at the de-
sign and implementation levels. As a consequence, signiﬁcant problems in aligning
data, processes, and protocols appear as soon as a speciﬁc piece of functionality is
used within a different application context—this has been conﬁrmed in numerous
studies, which estimate a market for integration solutions in the order of a magni-
tude of over one trillion of dollars.2 Technologies facilitating robust and scalable
interoperability are a must for an economically based ICT within enterprises and a
key component of the Internet of tomorrow.

In a business environment, it is the service that is important for a given cus-
tomer, not the speciﬁc hardware or software components that are used to deliver
this service. To a certain extent, the ICT industry responded to this challenge by
moving from software to “serviceware” on the basis of the emerging concept of
“Web services”. Currently, there is a paradigm shift in Computer Science: one gen-
eration ago, Computer Science learned to abstract from hardware to software; it
is now in a stage of abstracting from software to serviceware in terms of Ser-
vice Oriented Computing. At its core, this shift is concerned with the complex-
ity of properly handling services in large-scale applications. The concept of ser-
vice orientation is widely claimed to be the solution for the integration prob-
lem. However, it, in fact, implies that an additional step of abstraction in the de-
sign and development of ICT systems is still required in order to properly handle
the complexity of managing the potentially very large numbers of available ser-
vices.

In order for service-oriented technologies to scale, they will need to offer a sig-
niﬁcant degree of automation of service discovery, ranking and selection, compo-
sition, and invocation, as well as data-, protocol-, and process-mediation facilities.
Manual integration is not feasible when aiming at sophisticated means for manag-
ing systems that are dynamically composed of numerous services, and automation
can be achieved only if machine-processable descriptions of services are available.
Moreover, semantic descriptions of these artifacts are necessary in order to estab-
lish and warrant interoperability that does not require the human user to either be
present at all times of the process, or to manually hardwire certain integration so-
lutions that will be rapidly outdated, or hardly reusable in an environment with
such dynamic contexts. Such hardwired ad-hoc integrations only generate an ad-
ditional burden for the next integration wave, leading to an exponentially growing
problem. That is, semantics is required to achieve scalable and robust integration.
The principled combination of semantic and service-oriented technologies has been
motivated by the need to provide robust and scalable interoperability solutions in
both closed and open IT environments. Semantic descriptions of services facilitate
the ﬂexible integration among applications within and beyond enterprise bound-
aries.

Several research efforts have addressed the formal semantic descriptions of com-
putational artifacts in order to automate their use and reuse in software systems.

2Worldwide Enterprise Application Integration (EAI) Market. Venn Research Inc., March 2006.

1 Introduction

5

Based on previous works in formal software speciﬁcation and knowledge engineer-
ing, the latest development in this area is the concept of “Semantic Web Services”
(SWS). The SWS approach is about describing services with metadata on the ba-
sis of domain ontologies as a means to enable their automatic location, execution,
combination and usage. If services are described and annotated using machine-
understandable semantics, a service requestor may specify the service needed in
terms of the problem domain, or in other words, using business terminology. This is
a major progress compared to the traditional technology, as to date the discovery of
Web services is mostly based on signature matching or simply just on pre-deﬁned
addresses of the port to use. Further on, if the needs of the requestor cannot be ful-
ﬁlled by a single service, semantic descriptions of service capabilities, and the way
these services interact, can help to determine potential combinations of multiple
services to accomplish the desired task.

The Semantic Web Services solutions described in this book, including service
models, engineering methodologies, as well as development and execution envi-
ronments, will have to be revised to reﬂect the requirements raised by these new
scenarios. A large number of challenges are related not just to technology but also
to business, governance and society. Future Semantic Web Services approaches will
have to open up to adjacent disciplines such as service design and economics in
order to overcome such challenges in a networked society of tomorrow.

With more and more data being published on the Web, companies are ﬁnding
themselves in the position of having many critical business decisions rely solely
upon a large amounts of public (linked) data. There are several sectors in which this
can be clearly exempliﬁed. In manufacturing, for instance, the business–customer
relationship is no longer a one-way conversation where feedback can be con-
trolled through careful treatment of a few traditional reviewers and opinion-makers.
Through the Blogosphere, every Internet user is a potential reviewer and business’
attempted inﬂuence in this space is being carefully controlled. Instead, manufac-
turing businesses are turning more and more to eBusiness intelligence to track and
react to such options, involving customers worldwide in design and production pro-
cesses. In similar ways, sensor data increasingly informs business decisions in areas
as diverse as tourism, manufacturing (e.g., clothing), and banking. Recent events
in banking and World ﬁnance suggest that mining within such data sets could be
of critical importance in predicting trends. A service-oriented technology platform
supporting the realization of data-driven business applications as those afore men-
tioned will be one of the challenges for mastering large-scale data management
in corporate environments. This will require the deﬁnition of new service models
complying to the principles introduced by the Linked Data initiative, as well as new
approaches to implement classical service tasks such as discovery, composition and
mediation.

For Semantic Web Services to achieve industrial impact, it is essential for them
to comply with and be based upon established technology standards. Many activi-
ties related to this area are afﬁliated to W3C, including several of the approaches
presented in this book such as WSMO, OWL-S, SAWSDL, and more recently
WSMO-Lite and MicroWSMO. Efforts to standardize the conceptual model under-

6

1

Introduction

lying WSMO and OWL-S were undertaken in 2004/2005,3 followed by SAWSDL
in 2006/2007 in response to the need for more lightweight approaches building
upon traditional WS-* technology, providing a basic vocabulary to insert Seman-
tic Web references within a WSDL service description.4 The trend towards support
for RESTful functionality had led to further W3C member submissions such as SA-
REST, as well as WSMO-Lite,5 and soon MicroWSMO and hRESTS.6 WSMO-
Lite builds on SAWSDL, which itself extends WSDL. When using WSMO-Lite,
SAWSDL annotations can indicate more precisely the intent of the various other
annotations. The same applies for MicroWSMO annotations. To include support for
RESTful services, the SOA4All project (see Chap. 13) has developed MicroWSMO
and hRESTS, two micro-formats supporting RDFa that are used to structure the
HTML documentation of RESTful services so as to structure and organize the con-
tent of this documentation and facilitate machine-processability in a manner similar
to WSDL and SAWSDL.

A second category of impact creation activities concentrates on the alignment of
recent Semantic Web Services research with industrial initiatives, most prominently
USDL (Uniﬁed Service Description Language).7 Driven by SAP, USDL aims to
provide a uniﬁed approach to describe and access business, as well IT services, tak-
ing into account the way such services are currently exposed and consumed in cor-
porate environments—passing enterprise ﬁrewalls, within business networks, and as
part of on-demand applications delivered over the cloud. In particular, the initiative
puts emphasis on non-technical aspects of services, capturing the way consumers
understand details of business operations, pricing, legal and other implications of
using services. To increase its acceptance, the ultimate goal is to evolve USDL into
a standard applicable to all types of services on the Internet, and integrating ex-
isting approaches, including Semantic Web Services frameworks. Future research
will have to look into how this integration can be achieved in order to allow for an
optimal leverage of semantic technologies to achieve seamless interoperability and
scalability.

This book provides a comprehensive overview of Semantic Web Services in step
with the actual practice in the ﬁeld. It introduces the main socio-technological com-
ponents that ground the Semantic Web Services vision (Web and service science,
but also Web services in their SOAP and REST version) and several approaches
realizing it, most notably the Web Service Modeling Framework WSMF consisting
of the ontological service model WSMO, the WSML family of languages and the
WSMX execution environment, as well as its recent resource-oriented extensions
and underlying communication and coordination infrastructure. The real-world rel-
evance is pinpointed through a series of case studies in large-scale R&D projects

3OWL-S: http://www.w3.org/Submission/OWL-S, WSMO: http://www.w3.org/Submission/
WSMO/.
4http://www.w3.org/Submission/SA-REST/.
5http://www.w3.org/Submission/2010/SUBM-WSMO-Lite-20100823/.
6www.soa4all.org.
7http://www.internet-of-services.com/.

1 Introduction

7

from the last years and a business-oriented proposition by the Semantic Web Ser-
vices technology provider Seekda. Each chapter of the book is structured according
to a pre-deﬁned template, covering both theoretical and practical aspects, including
walk-through examples and hands-on exercises. As such, the book is suitable for
various audiences, as a state-of-the-art Semantic Web Services reference handling
the full range of topics and technologies associated to Semantic Web Services, but
also as an Computer Science textbook, primarily for an undergraduates course. The
book has 14 chapters; the core Chaps. 2 to 13 require approximately a two-hour
lecture each, thus the entire book can be taught during one semester. At the gradu-
ate level, the course could also include a selection of the complementary literature
provided as further reading for each chapter. Additional learning material, including
pointers to related education and training offers, is available at the book website at
www.swsbook.org.

The chapters of this book provide a comprehensive overview of the current state-
of-the-art of the formalisms, methods, tools and applications in the area of Semantic
Web Services. They demonstrate that the achievements of the research community
over the past years have resulted in technologies that are useful and applicable to
the requirements of various business scenarios. Nevertheless, when compared to
the more general IT landscape of the twenty ﬁrst century, the reader will easily note
that there are various signiﬁcant developments and application scenarios which have
not yet been considered in detail by existing Semantic Web Services solutions. In
particular, the rapid dispersion of mobile and sensor computing technologies into
numerous businesses, and as every-day life, the increasing importance of informa-
tion analytics leveraging the huge volumes of data published over the Web, and the
politically driven initiatives related to the design and development of principles, ar-
chitectures and core components of the Internet of the future, all deserve further
investigation.

The book is organized into four parts which, to some degree, can be read in-
dependently. The ﬁrst part (Chaps. 2 to 6) is dedicated to the scientiﬁc and tech-
nological foundations of Semantic Web Services; readers familiar with the basics
of Web services, World Wide Web or REST (Representational State Transfer) can
start directly with the second part of the book (Chaps. 7 to 9), in which the main
building blocks of the Web Service Modeling Framework are presented. The third
part of the book (Chaps. 10 to 12) can be seen as complementary to the core WSM*
work. Chapter 10 introduces Triple Space computing, a communication and coordi-
nation paradigm for Web services based on the Web principle of persistent publish
& read which promises to solve the autonomy issues known for message-based ser-
vices infrastructures. Alternative Semantic Web Services approaches are analyzed
in Chap. 11. The Web principle of persistent publish communication is also one of
the themes of Chap. 12 which presents a model for lightweight service descriptions
motivated by the raise of Web-based RESTful services. Finally, the fourth part of the
book (Chaps. 13 and 14) discusses real-world adoption of Semantic Web Services.
For a full comprehension of the case studies, it is advised that the reader studies
Chaps. 7 to 9, and possibly also Chaps. 10 and 12, as these chapters introduce the

8

1

Introduction

technologies validated through the case studies. Knowledge of the corresponding
R&D projects is, however, not compulsory, though surely helpful. Exercises are
given at the end of each chapter previously mentioned. They can be solved using
the notions introduced in the associated chapter, but may involve the installation of
additional software packages available on the Web.

Chapter 2
Web Science

Abstract Originally intended to be a simple way to share and interlink documents
over the Internet, the Web has evolved into one of the most complex technologies
currently available. This transformation took place in a short period of time, and
in a rather chaotic manner, leading to the current lack of structure, security and
conﬁdentiality including billions of duplicate information pieces. Thus to overcome
such issues, several key researchers contributing to the Web and related sciences are
pointing out the need for a new emerging science, the so-called Web Science.

2.1 Motivation

The Web has evolved substantially since its creation, becoming one of the most
complex technologies of the current time. Its evolution, initially driven primarily by
researchers and specialists, is now strongly inﬂuenced by its billions of user. The
Web Science is studying the Web transformation from its creation, to the present
times, as well as its possible evolution in the future. Furthermore, Web Science
delineates the directions in which it is expecting to further evolve. Web Science
aims to answer two main questions, namely:

• How the Web functions, by analyzing the components that enable it to act as a

decentralized information system [5].

• How Web traits arise and how they can be harnessed or held in check for the

beneﬁt of society.

As such, this science addresses the past, the present and the future of the Web.
By analyzing the past, one can determine what makes the Web what it is today. By
analyzing the trends and changes over the last few years, it can predict what the next
steps will be. And ﬁnally, taking the predicted next steps into consideration, certain
measures can be taken to enhance security, scalability, robustness or consistency.

This new discipline was formally launched in November 2006, when the Web
Science Research Initiative (WSRI)1 was founded. Since then, the initiative gath-
ered researchers from 16 top universities, and it is leaded by the most prominent

1http://webscience.org/.

D. Fensel et al., Semantic Web Services,
DOI 10.1007/978-3-642-19193-0_2, © Springer-Verlag Berlin Heidelberg 2011

9

10

2 Web Science

researchers in the ﬁeld (Tim Berners-Lee, Wendy Hall, Nigel Shadbolt, Danny
Weitzner, and James Hendler).

Web Science is rapidly attracting researchers and practitioners from all over the
world. Several universities are already providing extensive Web Science courses,
covering subjects like the current and emerging Web concepts, technologies and
Web-based software systems, social computing, networking and computational jour-
nalism.

Considering the vast area covered by Web Science, as well as the relatively short
period of time since its foundation, this chapter is presenting an overview of its main
activities and goals.

2.2 Technical Solution

As Web Science does not aim to solve a problem but rather tries to analyze an
existing technology, we cannot really talk about a technical solution, but rather a
technical approach for understanding the Web for developing this new, emerging
science.

As for any emerging discipline, the Web Science curriculum is continuously
evolving, with continuous growth in the number of areas of interest. There are, how-
ever, some fundamental research questions established as core elements of interest
for Web Science by the Web Science Research Initiative. Such research questions
cover:
• The history of the Web, how it transformed from a collection of documents to the

Web we know today.

• Building the Web, the mechanisms and infrastructure needed.
• The inﬂuence of the Web in Society, as well as the inﬂuence of society over the

Web.

• Operationalizing Web Science for a World of International Commerce.
• Analyzing the Web, its beneﬁts and its drawbacks.

Numerous courses and publication are addressing the cited research areas.
Among others, [8], [10] and [9] are analyzing the history of Web, W3C Recom-
mendation [1] describes the architecture of the Web, [7] analyzes the inﬂuence of
the Web in Society, while [5], [6] and [13] discuss the Web Science in general. The
ﬁnal objective is to determine its further evolution, long-term impact on the society,
beneﬁts and draw-backs.

In the following sections, we provide an overview of the topics introduced above.

This overview is based on existing publications as well as ongoing research.

2.2.1 History of the Web

In the present day society, almost everyone has at least a basic notion of the Web
origins and evolution. This section provides a short overview, based upon the World

2.2 Technical Solution

11

Wide Web Consortium (W3C) history of the Web2 and on the previously mentioned
publications.

The history of the WWW can only be analyzed in conjunction with the main
steps that led to its creation: the creation of the ﬁrst network (the Advanced Research
Projects Agency Network), its transition to the Internet, as well as the birth of the
World Wide Web.

2.2.1.1 The Advanced Research Projects Agency Network (ARPANET)

The ﬁrst small network was created experimentally in 1965, when a dial-up tele-
phone line was created to connect computers from Berkeley to the Massachusetts
Institute of Technology (MIT). This was the ﬁrst wide area network ever created.
In the next two years, research in this direction evolved substantially, and the
head of the Advanced Research Projects Agency (ARPA) computer research pub-
lished the plans for ARPANET, a computer network system. The publication of the
plans was the start of the collaboration between teams at ARPA, MIT, the National
Physics Laboratory (UK) and Research ANd Development Corporation (RAND),
which were previously working in isolation, towards the development of the ﬁrst
global network. Ideas from all these institutes were incorporated into the design of
ARPANET. By 1969, it was already possible to connect computers between Stan-
ford University and the University of California, Los Angeles (UCLA). By 1971,
there were 23 host computers linked by ARPANET.

2.2.1.2 The Beginning of the Internet

Since its inception, the aim of the Internet has been to provide a platform that
would allow humans to exchange information. In the early 1970s, the success of
the ARPANET led to the creation of a number of small, proprietary networks. In-
side a network, it was possible to send messages from one computer to another (i.e.,
from one person to another), which is now one of the most common uses of the
Internet—email. However, connecting these networks with each other required a
common communication protocol.

The close collaboration between ARPA and Stanford University scientists led
to the development of the ﬁrst common language that allows different networks to
communicate—the Transmission Control Protocol/Internet Protocol (TCP/IP).

This new development allowed humans to communicate asynchronously using
computers, but this did not solve the problem of ﬁle sharing and information access.
Even using File Transfer Protocol (FTP) servers, the ﬁrst ﬁle transfer technology,
people still needed to have previous knowledge of where certain information was
available. Thus, some form of human communication was required in order to be
able to transfer ﬁles.

2http://www.w3.org/History.html.

12

2 Web Science

2.2.1.3 The World Wide Web

The Internet was revolutionized in the early 1990s when the ﬁrst program, called
Gopher, allowing search on remote servers was developed at the University of
Minnesota.3 Gopher provided browsing facilities through hierarchies of application
links, ﬁle, directories, graphics, etc. on a remote machine, plus facilities to search
indexing servers.

However, this was only the ﬁrst step towards the Web as we know it today. The
true change and innovation was initiated by Enquire,4 a small, easy to use informa-
tion system developed by Tim Berners Lee. The World Wide Web (WWW) idea was
further developed, which led to the creation of what we know today—an easy-to-
use, easy-to-extend, easy-to-access global information system. The three pillars that
supported the WWW were HyperText Transfer Protocol (HTTP, a standard proto-
col for retrieving hypertexts and other documents), Uniform (or Unique) Resource
Identiﬁer (URI, a globally unique identiﬁcation system for every resource) and Hy-
perText Markup Language (HTML, a format for creating and laying out human-
readable, interlinked hypertext documents).

The ﬁrst Web page was also created by T.B. Lee in 1990, and a copy of this page

is still available online.5

The ﬁrst International Conference on the World Wide Web (1994) gathered 380
participants from all over the world.6 It laid the foundation for the creation of the
W3C coalition.

2.2.2 Building the Web

As described in the previous section, the success of the early Web Architecture was
based on three main building blocks, namely HTTP, URI and HTML. This section
provides an overview of these main pillars, as well as of the Web Architecture as
presented by the W3C recommendation [1].

2.2.2.1 HyperText Transfer Protocol (HTTP)

The Hypertext Transfer Protocol is an application-level protocol for distributed, col-
laborative, hypermedia information systems, which provides the means for a client–
server interaction. Its development was coordinated by the World Wide Web Consor-
tium and the Internet Engineering Task Force7 (IETF). The pre-standard HTTP/1.1,

3http://gopherproject.org/Software/Gopher.
4http://infomesh.net/2001/enquire/manual/.
5http://www.w3.org/History/19921103-hypertext/hypertext/WWW/TheProject.html.
6http://www94.web.cern.ch/WWW94/.
7http://www.ietf.org/.

2.2 Technical Solution

13

deﬁned in a series of Request for Comments,8 (RFCs) was rapidly adopted in mid
1990s. By 1996, it was supported in Netscape 2.0, Netscape Navigator Gold 2.01,
Mosaic 2.7, Lynx 2.5, and in Internet Explorer 3.0. The HTTP/1.1 standard was
released in 1997.

For accessing the Web resources, HTTP deﬁnes eight methods: HEAD, GET,
POST, PUT, DELETE, TRACE, OPTIONS, and CONNECT. The most important
are the request operations: GET, HEAD, PUT, DELETE, and POST. The GET
method is triggered any time someone tries to access a Web resource via a browser.
The URI associated to the GET deﬁnes the resource to be retrieved (i.e., its “ad-
dress”). The HEAD method returns only the headers, i.e., the size of the remote
resource and similar information (useful for testing); PUT is used to create a re-
source; DELETE, as the name suggests, is used for deleting a resource; the POST
method is to update a resource.

There are two commonly adopted versions of HTTP: HTTP/1.0 and HTTP/1.1.

Their deﬁnition can be found in RFCs 1945 (HTTP 1.0) and 2616 (HTTP 1.1).

2.2.2.2 Uniform Resource Identiﬁers (URIs)

Also initially deﬁned in RFCs, the URIs are strings used to uniquely identify re-
sources over the Internet. There are two types of URIs, namely the Uniform Re-
source Names (URNs) and Uniform Resource Locators (URLs). The distinction
between these two is that an URN deﬁnes the identity of a resource, while an URL
deﬁnes the way to ﬁnd it.

A URI consists of four elements [10]:

<scheme>://<authority><path>?<query>

where

Scheme denotes a protocol over which the respective resource is accessible
Authority shows the owning entity of the resource
Path provides the pointer to where the resource is available
Query is the query on the resource

Normally, one single URI should point to one single resource, and should remain

unchanged over time.

What makes a cool URI? A cool URI is one which does not change.
What sorts of URI change? URIs don’t change: people change them [4].

2.2.2.3 Hypertext for the Masses

Hypertext is text with references to other Web resources (hyperlinks). In other
words, hypertext is a simple way to construct documents that reference other re-
sources. The resources referred to are not limited to other documents, they can be

8http://www.rfc-editor.org/rfc.html.

14

2 Web Science

everything that is identiﬁed by a URI. There are currently two well known types of
hypertext documents: static and dynamic hypertext. Static hypertext refers to static
resources, which do not normally change their content or structure, and can be used,
for example, to create catalogues or to cross-reference collection of data in docu-
ments. On the other hand, the more complex type of hypertext can develop very
complex and dynamic systems of linking and cross-referencing.

The most famous implementation of hypertext is, of course, the World Wide

Web.

A number of characteristics are considered important in characterizing a good

hypertext [3]:

Lots of documents The hypertext’s power mainly comes from the fact that it pro-
vides an easy and rapid access to large amounts of data. The data are linked to one
another by hyperlinks.

Lots of links Every document can and should link to a multiple of other resources.
It should present the reader with several links, offering a choice about where to
go next. This is a different situation to the one where a document links only to
another one, in which case we have a sequence of resources. By allowing multiple
links, a hypertext allows the readers to select and follow the one which they are
interested in.

Range of Details The main difference between a hypertext and a normal text is
determined by the range of details it can offer. For normal text, adding more details
means simply making the document bigger and more difﬁcult to comprehend. For
a hypertext, the details can be added by creating hyperlinks to other documents. In
this way, readers can visit the content of the ﬁrst hypertext, and then, if interested,
further browse the details that interest them by following the associated links.

Correct links Many Web links are now pointing to unavailable resources. This is,
of course, due to the nature of the Web, which changes continuously. A way of
avoiding this situation would be to point only to resources under your control, but
this will limit the advantages offered by the hypertext and by the Web, in general.

2.2.2.4 Web Architecture

The Web Architecture was analyzed in several publications like [1] or [15]. In sum-
mary, the Web Architecture is two-tiered and characterized by a Web client that
displays information content and a Web server that transfers information to the
client [15].

The most important aspects that need to be considered regarding the Web Archi-

tecture are:

• The resources, i.e., what is represented.
• Identiﬁers, i.e., how the resources are identiﬁed over the Web (URI).
• Representation formalism, i.e., how the resources are represented, using what

formalism and what representation language.

2.2 Technical Solution

Fig. 2.1 Resources,
identiﬁers and representation

15

Figure 2.1 identiﬁes the relations between resources, identiﬁers and representa-

tion (from [1]).

Furthermore, the document identiﬁes a number of architectural principles, such
as Orthogonal Speciﬁcations, Extensibility, Error Handling, and Protocol-based In-
teroperability.

Orthogonal Speciﬁcations The technologies used for representation, identiﬁcation
and interaction may evolve independently. If the speciﬁcations are orthogonal, the
changes of one technology should not affect the others.

Extensibility The information on the Web, as well as the technologies used for
representing and identifying it, is evolving over time. One of the Web architecture
principles is to allow for the extensibility without affecting the interoperability.
Error Handling Every networked information system is subject to errors, and as
such it should implement some form of mechanism for error handling. Typically,
there are two important steps for error handling, namely error correction and error
recovery. The ﬁrst one means that an agent modiﬁes one or more conditions so that
it appears that the error never occurred (for example, some data may be retrans-
mitted). The second means that error is not repaired, and an agent continues the
execution, taking into consideration the appearance of the error.

Protocol-based Interoperability This last principle is referring to the fact that the
interfaces are deﬁned in terms of protocols. Using a certain protocol implies spec-
ifying the syntax, semantics, and sequencing constraints of the messages inter-
changed.

16

2.2.3 Web in Society

2 Web Science

Since its creation, the Web has strongly inﬂuenced the society, and the society has
inﬂuenced the Web. The WSRI identiﬁed several topics that should be addressed
regarding the relationship between the Web and the society. Some of these topics
address the economic inﬂuence of the Web, like e-Commerce, while the majority of
them refer to how social life is inﬂuenced by the existence of the Web.

2.2.3.1 E-Commerce

The e-Commerce (Electronic Commerce) refers to the selling and buying of goods
over the Internet. These goods can be products (for example, buying a T-shirt online)
or services (for example, consultancy or ﬁnancial services).

Depending on the participants in an e-Commerce activity, we can distinguish

between two types:

B2C e-Commerce activities conducted between businesses and consumers (busi-

ness-to-consumers).

B2B e-Commerce activities conducted between businesses (business-to-business).

E-Commerce is a research area that has been investigated for more than 30 years,
although the meaning has changed over the years. Initially e-Commerce was only
about the facilitation of commercial transactions by adopting electronic transaction
systems. In the late 1970s, however, two technologies were introduced that allowed
businesses to electronically send commercial documents like purchase orders or
invoices: the Electronic Data Interchange (EDI) and the Electronic Funds Transfer
(EFT). Ten years later, new forms of e-Commerce, targeting the banking domain,
were already widely in use (like credit cards or ATMs).

Online shopping, the most well-known form of e-Commerce of our time, was
introduced in 1979. Two years later (in 1981) the ﬁrst B2B online activity was
recorded, followed in 1984 by the ﬁrst B2C activity. The e-Commerce activities
experienced a major expansion with the invention of the Web and the wide usage of
the Internet. This lead to the need for security protocols and regulations, but by the
end of 2000 most major companies were offering their products and services online.

2.2.3.2 IP and Copyright

As the Internet is now widely used, and people all over the word are publishing the
results of their work online, the Intellectual Property (IP) rights and the copyrights
are becoming a most pressing issue.

The IP rights refer to the use of ideas or expressions, and represent temporal mo-
nopolies imposed by the state. They are usually imposed on non-rival goods which
can be used simultaneously by multiple users (for example, they can be copied by
multiple users).

2.2 Technical Solution

17

Copyrights impose more strict restriction, as only the owner of the copyright can
use that particular product. As in the IP’s case, the good can also be an idea or an
expression, but it can also include rival goods.

2.2.3.3 Co-Evolution of Society and Web

It is a well-known fact that society inﬂuences the Web and the content published on
the Web, just as the Web inﬂuences the society.

Since its invention, the Web has evolved into an infrastructure developed by all
its users. Every person that publishes something online is a contributor to the Web’s
development. Every person creating a personal proﬁle (for example, on Facebook)
brings his own contribution to the Web. Furthermore, there are users who publish
information on the Web with the purpose of helping others to better understand
certain concepts (Wikipedia is a good example of this).

Furthermore, the Internet is affecting our social life. Instead of calling our
friends, we now “skype” them. Instead of asking somebody if he or she is avail-
able for a meeting, we search for their online calendar. This undoubtedly makes
things easier and faster, but are there negative effects that should be considered?

Unfortunately, the answer is yes. On the one hand, we tend to retreat into some
kind of “virtual reality”. Numerous psychological studies are raising the alarm on
the negative effects the Web has over our social life. Teenagers that grow up with
the Internet tend to ﬁnd face-to-face communication difﬁcult, and are unable to deal
with real-word situations. Instead, they prefer to retreat into the world of the Web
where they can hide under some user names and live in their virtual reality.

Another negative effect is that there is no control over the information that is
available. Most of the times when we try to access a so-called safe Web site, we
are exposed to advertisement, or even pornographic materials. Adults are able to
simply ignore them, but the effects on children and teenagers are devastating and
beyond measurement. Furthermore, subscribing to a new email list or social network
exposes you to unwanted emails, ranging from announcements that you have just
inherited a huge amount of money from an unknown relative, to the more damaging
viruses.

2.2.3.4 Globalization

The term globalization describes an ongoing process by which regional economies,
societies and cultures have become integrated through a globally-spanning network
of exchange.

The Web provides a robust support for globalization by allowing seamless com-
munication between users all over the word. The impact of the Web and of the
Internet on globalization is both positive and negative.

One of the positive effects, and probably the most noticeable, is in regards to the
business sector. The Internet provides a new and challenging environment where the

18

2 Web Science

rules of competition are constantly changing. This creates modernization and inno-
vation on daily basis, and, ultimately, the end user is the one that beneﬁts from this
competition in terms of quality of products and services as well as in terms of cost.
The way services are sold and delivered is highly inﬂuenced by the Internet, a net-
work available all over the world. Due to its distributed nature, the communication
between service providers and consumers is ‘at one click distance’, and this allows
for client–business relationships which require very little effort from the client.

On the other hand, the negative effects also need to be taken into considera-
tion. One unfortunate truth is that there are huge technological differences between
countries, and the Web, in the majority of cases, is making this gap wider rather than
reducing it. Developed countries will advance even faster thanks to easy access to
novel information, while less developed ones do not have this beneﬁt as they do not
have the proper infrastructure to access the Web.

2.2.3.5 Collective Intelligence

One of the main advantages of the Web is that it allows for the building of reposi-
tories of knowledge based upon the experience of multiple users. The most relevant
example of this is Wikipedia where multiple users can input data based on their own
expertise.

However, there are important aspects which hamper the potential beneﬁt of the
Web: How to integrate the inputs of multiple users? How to select the correct in-
formation out of the inputs received? One possibility, the one implemented by
wikipedia, is simply to allow any user to provide input, with the risk of having
other users contradicting their opinion. This, however, may lead to pages containing
contradictory data, which is not really useful when trying to ﬁnd information.

A different approach for managing collective intelligence is through a vote-based
system. This approach assumes the probability that more people answering a ques-
tion or providing information are correct than the probability that most people are
wrong. A variant of this approach is to ask the users to rate certain information or
products (for example, an article or an essay). If most of the people that rated the
product are considering it valuable, the product is ranked accordingly. If most of the
people rating it are considering the product of poor value, or even containing wrong
information, the administrator may even consider removing it.

2.2.4 Operationalizing the Web Science for a World

of International Commerce

As mentioned in the previous sections, the Web inﬂuences the society just as the
society inﬂuences the Web. This section further analyzes several steps that need to
be taken in order to operationalize Web Science for a world of international com-
merce. The previous sections also underlined how the end-user beneﬁts from the

2.2 Technical Solution

19

new challenges faced by the service providers, while this section will further focus
upon the steps that need to be taken by service providers. WSRI identiﬁes several
topics relevant for this domain, such as the adopted business strategy, the regulation
and security aspects, the online markets and the relationship between design and
evolution.

2.2.4.1 Business Strategy

In developing a new online business, one must ask oneself a very important ques-
tion: What makes this business different from others that offer similar products or
services? Given the realities of globalization and the easy dissemination of ideas, it
is hardly probable that one business identiﬁes itself based on the offer. What makes
the difference is, in most cases, the adopted business strategy.

There are many business strategies that can be followed, depending on the prod-
uct offered, or on the clients targeted. For example, [14] points out that one key
advantage of online commerce over ‘normal’ commerce is that a service deployed
online is accessible to millions of users. This leads to the identiﬁcation of the ﬁrst
requirement for a solid business strategy: manner of presentation of the information
or the services, as well as easy access and easy payment are a must. Furthermore,
[14] prescribes several requirements for an e-Commerce Web site. According to the
author, it should provide:
• A ‘Uniﬁed Storefront’ that is a well-displayed showcase of products.
• A ‘Shopping Cart System’ where the client places the selected products.
• A system that integrates the online data transactions and e-Commerce payment

solutions with the provider’s existing accounting system.

• A ﬁne-tuned Search option to locate just the kind of product the client wants.

Apart from these speciﬁc Web features, the business strategy that governs an
online business is similar to the business strategy that governs any other business.
The only difference is that the client cannot manually browse the products, and as
such, the user interface should be good enough to convince him or her to try out a
particular online service or buy a product.

2.2.4.2 Regulation and Security

Regulation and security play an important role for the online commerce. Everybody
can sell or buy something online, or even download products for free, but there are
certain rules that need to be followed by both the service providers and consumers.
Different countries have different rules regarding the e-Commerce, restricting both
the type of products commercialized (for example, some countries may prohibit
certain type of music) or the authorized sellers. This complements the IPs and copy-
right previously described, as, for example, you cannot multiply and sell a DVD for
which you don’t own the copyright.

20

2 Web Science

For most of us, however, of importance are the regulations protecting the clients.
Whenever we perform an online transaction, we provide personal information, like
address and credit card details. In this regard, the question of who controls the data
cannot be ignored.

In response to this question, several data security standards have been created,
such as the PCI security standard. There are also attempts from several govern-
ments to at least partially control the personal data. Unfortunately, even if rules and
regulations exist, there are more and more accidents involving the loss of conﬁden-
tial, personal data (see, for example, details of how the un-encrypted data of 43,000
children were lost http://news.zdnet.co.uk/security/).

A second important aspect regarding security involves avoiding the spyware pro-
grams. The spywares are computer programs that extract data from the host com-
puter and transmit it to a predeﬁned address. Although there are several rules that
prohibit the distribution of such programs, they still exist and every computer con-
nected to the Internet is a possible target. Unfortunately, spywares do not limit them-
selves to our home-computers where we can implement whatever security measures
we ﬁnd. In order to avoid loss of data, very strict rules are imposed on the service
providers which are manipulating the personal data of their customers.

2.2.4.3 Online Markets

The online marketing, also known as Internet marketing or Web marketing, is the
marketing of products or services over the Internet. It ties together creative and
technical aspects of the Internet including, design, development, advertising, and
sales.

There are several business models associated with the Internet market, such as:

• E-Commerce—as described in the previous sections, e-Commerce concerns the
selling of goods directly to the consumers or to other businesses (B2C and B2B).

• Publishing—the sale of advertising.
• Lead-based Web sites—an organization that generates value by acquiring sales

leads from its Web site.

• Afﬁliate marketing—this is the process in which a product or service developed

by one person is sold by another active seller for a share of the proﬁts.

A number of advantages of using Internet markets, from both the providers’ and
consumers’ perspective, have been identiﬁed. First of all, it is relatively inexpen-
sive, and allows businesses to reach a far wider audience than traditional markets
with a reduced advertising cost. In addition, the consumers may buy products and
services whenever they want, regardless of their geographical location. Second, the
providers can easily make statistics regarding what category of people are buying
which products, and use this data to optimize their business model. They can also
determine what kind of advertisement will be more appropriate, in order to increase
their sales.

2.2 Technical Solution

2.2.5 Analyzing the Web

21

Analyzing the Web means extracting information about the Web and its users based
on the Web site accessed, number of hits or proﬁle of the users. These analyses are
usually performed by a Web log analyzer, a program that parses the log of Web
servers and determines who accesses it (the type of users), when, or in what way.
They can also include measurements referring to a potential audience or voice shar-
ing.

There is a typical set of parameters usually considered by a Web analyzer. These
parameters range from information about the users to technical detail about the ser-
vice. Among other parameters, the typical set includes:
• Number of visits and number of unique visitors.
• Visits duration and last visit.
• Authenticated users, and last authenticated visits.
• Most viewed, entry and exit pages.
• Files’ type.
• Search engines, key phrases and keywords used to ﬁnd the analyzed Web site.
• HTTP errors.

A comparative analysis of different sites may provide an overview of the general
interest of the Web users, and may also lead to an educated guess regarding the fu-
ture of the Web. Elon University conducted a survey on the future of the Internet.9
The respondents were asked to envision the Internet in 2020; all of them were tech-
nology experts and social analysts, and their answers (taken from [2]) include the
following quantitative results:
• About 77% said that the mobile computing device (the smartphone) with more
signiﬁcant computing power will be 2020s primary global Internet-connection
platform.

• 64% favored the idea that 2020 user interfaces will offer advanced touch, talk and

typing options and some added a fourth “T”—think.

• Nearly four out of ﬁve respondents (78%) said that the original Internet architec-

ture will not be completely replaced by a next-generation net by 2020.

• Three out of ﬁve respondents (60%) disagreed with the idea that legislatures,
courts, technology industries, and media companies will exercise effective intel-
lectual property control by 2020.

• A majority—56%—agreed that in 2020 “few lines (will) divide professional from

personal time, and that’s OK”.

• 56% said that while Web 2.0 is bringing some people closer, social tolerance will

not be heightened by our new connections.

• 45% agreed and 44% disagreed with the notion that the greater transparency of
people and institutions afforded by the Internet will heighten individual integrity
and forgiveness.

9Available at http://www.elon.edu/e-web/predictions/expertsurveys/2008survey/default.xhtml.

22

2 Web Science

• More than half (55%) agreed that many lives will be touched in 2020 by virtual
worlds, mirror worlds, and augmented reality, while 45% disagreed or did not
answer the question.

2.3 Web 2.0

As a straightforward consequence of having an exponentially growing number of
users and of being part of day-to-day activities for personal and business beneﬁts,
the Web has already moved in new directions. We are now dealing with a Web that
is mainly directed towards supporting collaborations in terms of Web applications,
that gives its users the choice to interact and collaborate in a social media dialogue as
creators of user-generated content. As illustrations of what Web 2.0 implies, we can
consider social-networking sites, blogs, wikis, video-sharing sites, hosted services,
Web applications and folksonomies.

The characteristics of Web 2.0 were summarized by [11] using the acronym

SLATES (Search, Links, Authoring, Tags, Extensions, Signals):

Search provides support for keyword search for ﬁnding information.
Links connect information together.
Authoring every user has the ability to create content in a collaborative manner.
Tags allow the categorization of content by the users by adding tags.
Extensions imply that the Web is both an application platform as well as a document

server.

Signals notify the users of changes in the content.

It is, however, important to note that Web 2.0 is based on ideas and principles,
and not on particular technologies. Tim O’Reilly considers it as consisting of a
so-called gravitational core [12], formed based on core-competencies, which links
equally to technologies, ideas, and further development opportunities, as presented
in Fig. 2.2.10

2.4 Conclusions

This chapter presents Web Science as the new emerging discipline which aims to
investigate the past, the present and the future of the Web. This discipline is still
not fully deﬁned: a group of experts have so far only developed the curriculum that
should be addressed. The areas range from the history of the Web to the analyses of
the Web, and through the experts aim to determine the next phases in the evolution
of the Web.

Every topic addressed in the curriculum was described in this chapter. However,
the vastness of the domain does not allow for a detailed presentation of each of these

10http://oreilly.com/pub/a/web2/archive/what-is-web-20.html?page=1.

References

23

Fig. 2.2 Resources, identiﬁers and representation

topics. As such, the chapter is merely meant to initiate the reader to Web Science,
and to present its basic concepts and ideas.

References

1. Architecture of the World Wide Web, volume one. http://www.w3.org/TR/webarch (2004).

http://www.w3.org/TR/webarch. Stand: 15.4.2009

2. Anderson, J.Q., Rainie, L.: The future of the Internet III. Tech. rep. (2008)
3. Baccala, B. (ed.): Connected: An Internet Encyclopedia. http://www.freesoft.org/CIE/index.

htm

4. Berners-Lee, T.: Cool URIs don’t change (1998). http://www.w3.org/Provider/Style/URI.

html

5. Berners-Lee, T., Hall, W., Hendler, J.A., O’Hara, K., Shadbolt, N., Weitzner, D.J.: A frame-
work for Web Science. Foundations and Trends in Web Science 1(1), 1–130 (2006).
doi:10.1561/1800000001

6. Berners-Lee, T., Hall, W., James, H.A.: A Framework for Web Science. Foundations and
Trends(r) in Web Science. Now Publishers, Hanover (2006). http://www.amazon.com/exec/
obidos/redirect?tag=citeulike07-20&path=ASIN/1933019336

7. Boyera, S.: How to achieve global impact? WWW Foundation (2009)
8. Gillies, J., Cailliau, R.: How the Web Was Born: The Story of the World Wide Web. Oxford

University Press, Oxford (2000)

9. Herman, A., Swiss, T.: The World Wide Web and Contemporary Cultural Theory: Magic,
Metaphor, Power. Routledge, London (2000). http://www.amazon.com/exec/obidos/redirect?
tag=citeulike07-20&path=ASIN/0415925029

24

2 Web Science

10. Lee, B.T., Fischetti, M.: Weaving the Web: The Original Design and Ultimate Destiny of the

World Wide Web by Its Inventor. Harper, San Francisco (1999)

11. McAfee, A.: Enterprise 2.0: the dawn of emergent collaboration. MIT Sloan Management

Review 47(3), 21–28 (2006)

12. O’Reilly, T.: What is Web 2.0, Design Patterns and Business Models for the Next Generation

of Software. http://oreilly.com/pub/a/web2/archive/what-is-web-20.html?page=1

13. Shadbolt, N., Berners-Lee, T.: Web science: Studying the Internet to protect our future. Scien-

tiﬁc American Magazine (2008)

14. Stewart, B.: E-business strategy vital for e-commerce Web solutions. http://ebay123.50webs.

com/e-business-strategy-vital-for-e-commerce-web-so.html

15. Thompson, C., Hansen, G.: Current Web architecture. http://www.objs.com/survey/WebArch.

htm

Chapter 3
Service Science

Abstract The goal of Service Science as a discipline is to promote service innova-
tion and increase service productivity. It focuses on accommodating multiple clients
and multiple providers’ needs, as well as on the multi-phase business processes.

3.1 Motivation

Service Science represents an interdisciplinary discipline aiming to study, design,
and implement service systems,1 taking into consideration speciﬁc arrangements of
people and technologies that take actions which provide value for others. It focuses
upon innovation in the service sector, and it is proposed as an academic discipline
and research area that complements other disciplines contributing to the knowledge
of services—in this sense having common pillars with the Web Science previously
described in Chap. 2.

Service Science is an interdisciplinary ﬁeld, focusing on services as systems of
interacting parts. A service should be seen as a complex system that involves people,
technology, and business. All of this being considered, Service Science is based on
a multitude of existing disciplines such as computer science, economics and human
resources management.

The most well know initiative around Service Science is Service Science, Man-
agement, and Engineering by IBM.2 HP is also showing an increasing interest
in Service Science and created the Centre for Systems and Services Sciences,3 a
multi-institution initiative for developing and integrating the sciences that lead to
the successful analysis, design and control of complex systems characterized by
services requirements. Oracle Corp., one of the biggest software companies (which
in 2007 had the third-largest software revenue according to [8]), created an industry
consortium, the so-called Service Research and Innovation Initiative, focusing
on establishing the service science as a key investment area by companies and gov-
ernments as well as an academic discipline.

1http://en.wikipedia.org/wiki/Service_Science,_Management_and_Engineering.
2http://www.ibm.com/ibm/ideasfromibm/us/compsci/20080728/index.shtml.
3http://www.hpl.hp.com/research/about/model.html.

D. Fensel et al., Semantic Web Services,
DOI 10.1007/978-3-642-19193-0_3, © Springer-Verlag Berlin Heidelberg 2011

25

26

3 Service Science

The European Service and Science Initiative (NESSI) network has established
a Services Sciences and Systems Engineering Working Group4 which also envis-
ages a multi-disciplinary approach to address some of the challenges incurred in
understanding services.

3.2 What Is a Service?

In the literature on the subject, we can ﬁnd many deﬁnitions of a service:

Services are economic activities offered by one party to another, most commonly
employing time-based performances to bring about desired results in recipients
themselves or in objects or other assets for which purchasers have responsibility. In
exchange for their money, time, and effort, service customers expect to obtain value
from access to goods, labor, professional skills, facilities, networks, and systems; but
they do not normally take ownership of any of the physical elements involved [9].

A service is a time-perishable, intangible experience performed for a customer

acting in the role of a co-producer [3].

A service is the application of specialized competencies (knowledge and skills),
through deeds, processes, and performances for the beneﬁt of another entity or the
entity itself.

In order to optimize services, improve access of customers to services and ensure
an optimal price/optimal ratio, Service Science studies different aspects related to
the services life-cycle.

Service Science and IT IT services (or e-Services) are services offered or de-
ployed using IT infrastructure. As such, they are considered a sub-class of the more
general services, and they are also the subject of the Service Science discipline.
Studying e-Services represents a sub-domain of the service science, in general.

As such, a number of topics can be identiﬁed as relevant for IT Service Science:

• Service analysis, design, development and testing.
• Service orchestration, composition and delivery.
• Service innovation.
• Service design approach.
• Service pricing method and economics.
• Service quality measurement.
• Service technologies.
• Service applications.

The service analysis, design, development and testing represent the pre-
deployment phases necessary for every service, be it an IT service or other. During
these phases the market observations and feasibility studies are performed. A com-
plete analysis of what the service and conditions with which it should comply is also

4http://www.nessi-europe.com/Nessi/Workinggroups/HorizontalWorkingGroups/
ServicesSciences/tabid/244/Default.aspx.

3.3 Service Analysis, Design, Development and Testing

27

performed during this phase (requirement analysis). Based on the requirements, the
service is designed, developed and ﬁnally tested before being deployed.

The service orchestration, composition and delivery refers to the combination
of multiple services in order to achieve a common goal. These phases can again
appear for both IT and non-IT services. In the IT domain, the problem, however,
escalates to data or process heterogeneity issues, due to machine-to-machine com-
munication.

Service innovation refers to several things, such as innovation in service prod-
ucts, service processes or service ﬁrms and companies. TEKES5 provides the fol-
lowing deﬁnition for service innovation [7]: Service innovation is a new or sig-
niﬁcantly improved service concept that is taken into practice. [. . . ] A service
innovation always includes replicable elements that can be identiﬁed and sys-
tematically reproduced in other cases or environments.

Service design approach refers to the determination of different methodologies
for developing different services, depending upon their functionality, deployment
environment, users, and so on.

Service pricing method and economics addresses several aspects regarding the
cost of using the service as well as payment methodology. For every service (both
IT and non-IT) during this phase, the relationship between production cost and the
price of using the service should be taken into consideration.

Service quality measurements refers to the quality of the service offered. There
are several methodologies for assessing the quality, as further presented in this chap-
ter.

Service technologies refers to the technologies used by the service. For the IT

domain, this also refers to the technologies needed to invoke the service.

Service applications is primarily a term used for e-Services, and refers to the

application domain of a service.

The following sections will analyze each of these topics, providing an overview

of the main points of interest in Service Science.

3.3 Service Analysis, Design, Development and Testing

The ﬁrst step in the development of a service, which is intensively studied by Ser-
vice Science, is the analysis of the service that is to be provided. This phase should
answer questions like: Which consumer groups are targeted? What are the cus-
tomer’s expectations? What are the challenges faced by the service? What is differ-
ent/additional about this service compared with other services possessing a similar
functionality?

The service provider has to take into consideration the needs of the customer so

that the offered service:

5http://www.tekes.ﬁ/en/community/Home/351/Home/473/.

28

3 Service Science

• Answers customer needs.
• Is priced reasonably.
• Has an aesthetic/attractive appearance.

Some other issues regarding e-Services are equally important from the customer
perspective. Among these, the service designer has to consider a number of non-
functional properties such as robustness, availability, facility of use, and security.

Based on these requirements, the designer provides the initial design of the ser-
vice. There are several methodologies that can be considered, which will be further
described in Sect. 3.6.

The design phase is followed by initial implementation efforts and testing. Usu-
ally, a set of pilot consumers are used for testing, and/or several test-cases are de-
veloped. Two crucial questions are answered during this phase:
• Does the service meet the business and technical requirements that guided its

design and development?

• Is the service working as expected?

There are several testing topics that need to be considered when testing an e-
Service, which are the same as the important topics when testing any software prod-
uct:

Scope—to detect existing failures to be corrected. This does not imply that all
the failures can be detected, as testing cannot establish that a product functions
properly under all conditions, only that it does not function properly under speciﬁc
conditions.

Functional vs non-functional testing—for e-Services functional and non-
functional requirements are equally important. The ﬁrst set refers to the functional-
ity of a service, while the second addresses questions like: How easy is it to use the
service? Is the service robust and secure? (a mandatory feature for every business
transaction), and so on.

Defects and failures—this particular aspect of the testing refers to the errors in
the development processes which, in case of e-Services, can hamper the interaction
with the consumer.

Finding faults early—as stated in [4], the sooner an error is identiﬁed, the
cheaper it is to correct it. Testing a service before its release minimizes the risk of
ﬁnding errors after its deployment, which potentially leads to retracting the service
and dealing with dissatisﬁed customers.

There are also a number of testing approaches that should be taken into consid-
eration, similar to the ones for testing software products: black box, white box or
grey box testing. In the black-box case, the testers have absolutely no knowledge
of the implementation details; in this case, the most appropriate testing method is
by using pilot customers, interested only in what the services offers. The second
type of testing, the white box, involves previous knowledge of how the service was
developed; in this case, the appropriate testers should have deeper knowledge of the
requirements (both functional and non-functional), as well as basic knowledge on
the technologies and development methodology used. The third approach represents
a combination of the previous two.

3.4 Service Orchestration, Composition and Delivery

29

Fig. 3.1 Spiral approach for software development

The results of the testing phase are fed back into the analysis and design phases;
the entire process follows a spiral approach [1] which may be executed several times
before the service is deployed (see Fig. 3.1).

3.4 Service Orchestration, Composition and Delivery

The service orchestration, composition and delivery refers to the deployment of a
service, as itself or as part of a composition of services. In the second case, there are
a number of heterogeneity issues that need to be taken into consideration, while the
composition and orchestration of services represents a challenging research topic in
itself.

This chapter further develops service delivery, disregarding its possible interac-
tions with other services, but rather, considering only one e-Service and its customer.
The development and deployment of a service is not an activity that can begin
from scratch, but rather reuses an existing infrastructure suitable for speciﬁc types of
services. This infrastructure, known as Service Delivery Platform, is to be further
adapted for given types of services. The adaptation in its turn can be used for every
service conforming to the same pattern. Service Science studies the existing plat-
forms, and prescribes the minimal set of components that should be implemented.

30

3 Service Science

Service Creation Environment provides support for the creation of services, for
example, in telecommunication domain, this environment should facilitate the rapid
creation of new communication services.

Execution Environment must provide support for the actual execution of the
service. It should be able to deal with conﬁdential customer data (such as bank
account information) as well as service speciﬁc data.

Presence/Location Component refers to both the virtual and the physical loca-
tion of both the consumer and the service. In the case of e-Services, this aspect is not
as important as in the case of traditional services (i.e., a customer in Germany may
use a service located in the UK). What is of primary importance in the e-Services
case is the context, i.e., the cultural and background information relevant to the two
entities.

Integration Component takes into consideration the aspects related to the tech-
nologies used by the service as well as those used by the client. The integration
should be seamless and transparent, at least from the perspective of clients. Ideally,
every integration problem should be determined and solved during the testing phase
as part of subsequent development efforts.

Service Oriented Architectures (SOAs) can be used as application integration
technology within a service delivery platform. SOAs can also be used to standardize
an reuse operational processes across service delivery platforms.

Two of the most widely used service delivery platforms are the HP Delivery

Platform6 and the Oracle Communication Service Delivery.7

3.5 Service Innovation

Service innovation refers to reusing existing services in order to provide novel,
improved ones. It can address several aspects, depending on whether the point of
view is from that of the service, the customer or the provider: innovation in ser-
vices—new or improved service products; innovation in service processes—new
or improved ways of designing and producing services (for example, technologi-
cal improvements); innovation in service ﬁrms, organizations, and industries—
innovations within the organization providing the service.

Any type of innovation applied should, however, consider all actors. For ex-
ample, a technological innovation that may reduce the costs of the service from
the provider’s perspective should also be weighted against the effects it has on the
consumer—is it making the service slower, insecure or not robust enough?

In [2], four dimensions of service innovation can be identiﬁed:

Innovation of the Service Concept it refers to a service concept that is new to its
particular market. In many cases, the innovation of the service concept involves

6http://www.hp.com/hpinfo/newsroom/press/2007/071107xa.html.
7http://www.oracle.com/industries/communications/oracle-communications-services-delivery.
html.

3.6 Service Design Approach

31

intangible characteristics of the service (for example, a new type of bank account
or information service).

Innovation of the Client Interface particularly important for e-Services, this type of
innovation refers to transformations of the interface between the service provider
and its customers.

Innovation of the Service Delivery System it relates, but it is not limited to, the
client interface. The innovation of the Service Delivery System includes any in-
novations of the service delivery platform.

The efforts from [2] are continued in [5], which provides a classiﬁcation of the

innovation techniques depending on the phase in the service lifecycle they affect.

Innovations associated with services production refer to innovation areas relevant
for e-Services: technology, organization of internal processes, production and or-
ganization of industry.

Innovations associated with services product refer to innovation in the nature of the

product and its features.

Innovations associated with services consumption address the delivery of the prod-

uct, the role of the consumer as well as the organization of consumption.

Innovations associated with services markets refer to innovation in the organization

of markets and in the marketing of the service.

From the service science perspective, innovation of services is one of the most
important study topics. By innovation, new improved services can be created out
of existing ones, at a minimum cost (in terms of both time and money). In addi-
tion, different innovations performed on the same service may lead to the creation
of multiple services. For the IT services, innovation implies transformation in the
service’s components.

3.6 Service Design Approach

The service design is the activity of planning and organizing people, infrastructure,
communication and material components of a service. The goal of this activity is
not only to create the initial service, but also to improve its quality, the interaction
between service providers and customers and the experience of customers.

The Service Design methodologies are used to organize people, infrastructure,
communication and material components. The design of a service may involve re-
organizing the activities performed by the service provider as well as the redesign
of interfaces and interactions that customers use to contact the service provider (for
e-Services this is referring to a Web site, user interface, blog, etc.).

Service design requires methods and tools to control all the elements of the de-
sign process, including the time and the interaction between actors. Three directions
of service design are identiﬁed in [6]:

Actors identiﬁcation of the actors involved in the deﬁnition of the service
Scenarios deﬁnition of possible service scenarios

32

3 Service Science

Service representation of the service, using techniques that illustrate all the compo-

nents of the service

The design is based on a set of functional and non-functional requirements for
the service. The ﬁrst step is the identiﬁcation of the actors, i.e., which entities will
play which role(s) in using the service (such as service provider, requester, and
so on). The second step is for each of these actors to strictly identify the type of
interactions they will have with the service, the expectations of those actors, as well
as the inputs they may provide to the service. This is part of the scenarios deﬁnition,
which should contain enough details for the service developers. These scenarios
should cover a broad area of use cases, of service usage possibilities. The last step
is the actual design of the service in terms of UML diagrams or any other modeling
language.

3.7 Service Pricing Method and Economics

The service pricing and economics phase should strongly reﬂect the cost of devel-
oping and providing the service, as well as the beneﬁts for the customer using the
service.

There are two well known pricing methods for e-Services, namely Flat Fee Ser-
vices Pricing and Rate Based Services Pricing, each of them having advantages and
disadvantages from the perspective of both provider and customer.

Flat Fee Services Pricing is a ﬁxed price for a speciﬁc service. This ﬂat rate
should be payed by the customer at regular intervals, established by a contract be-
tween the provider and the consumer, and the customer can use the service as much
as she/he want for the same rate. A number of e-Services traditionally offer ﬂat free
service pricing, such as Internet service providers or telecommunication providers.
Rate Based Services Pricing is a variable rate, based on the principle “pay as

you use”. There are three variants of rate based service pricing:
• Hourly Invoiced Services—billed purely based on the amount of time spent using

them. A common example is again the Internet usage.

• Retained Services Packages—available in a variety of sizes to the customers
needs. Usually the hourly rate is smaller as the size of the package increases.
• Monthly Retained Services—allow the customers to pay a monthly fee to receive

a pre-set amount of time to be used within a month.

3.8 Service Quality Measurement

Quality of Service (QoS) refers to non-functional properties of a services which can
be measured based on different parameters. Depending upon the type of service,
different quality measures are taken into consideration. The most common ones,
usually considered for e-Services, are listed below:

3.9 Service Technologies

33

Availability qualitative aspect reﬂecting whether the service is ready for immediate
use. It represents the probability that a service is available. A high probability
means the that service is available most of the times (and 100% availability implies
that the service is always available).

Accessibility qualitative aspect which can be represented as a probability, calcu-
lated as the success rate or chance of a successful service instantiation at a given
point in time.

Integrity measures the success of the service in maintaining correct and consistent

data.

Performance qualitative aspect measured in terms of throughput (the number of
service requests served at a given time period) and latency (time between sending
a request and receiving the response).

Reliability the degree to which it is capable of maintaining the service and service
quality. For example, the number of failures per month or year represents a measure
of reliability of an e-Service.

Regulatory measures how the service complies with a set of given rules or stan-

dards.

Security mainly refers to conﬁdentiality and non-repudiation. Security aspects deal
with, for example, in the case of e-Services, the authentication of the parties in-
volved, encryption of messages, and access control.

3.9 Service Technologies

Service technology refers to the set of technologies needed for developing and pro-
viding a service. Considering the diversity of service types, there is no strict and
well deﬁned set of technologies that services should use. For e-Services, however,
there are a number of key components that should be considered.

The ﬁrst one is, as previously mentioned, the service delivery platform. However,
the provider of a service may choose to develop it from scratch, not reusing any of
the existing platforms.

One mandatory component for e-Services is a user interface by which the cus-
tomer may access the service. This user interface should be as simple and user-
friendly as possible, and should preferably assist the customer in using the service.
Another component of the e-Services should be available for allowing the cus-
tomer to pay for the service he or she uses. Whether this is done by credit card,
PayPal, standing orders, or any other payment options, it should not be restricted in
any way. The only requirements is that a payment agreement be reached between
the service provider and consumers.

Other components that may be part of the technologies used by the service are
integrator, composer and orchestrator. These components are needed in case the
service has a complex structure and involves cooperation with multiple services or
multiple data formats.

34

3 Service Science

3.10 Service Application

Service application refers to the ability to create and deploy a service. Like in the
case of service technology, the diversity of services prohibits the existence of a strict
set of service application methodologies or tool support. There are, however, a num-
ber of service application frameworks which are suitable for e-Services. Among
these, the Microsoft Service Application Framework8 is one of the most commonly
used. It has a number of features that help the service providers in developing new
services, such as:
• Improved development experience—it allows service developers to truly fo-
cus on the business logic of their applications, by providing support for writing
code to conﬁgure a server that runs Internet Information Services (IIS), installing
a Secure Sockets Layer (SSL) certiﬁcate, creating a virtual directory, managing
credentials for a pool of application users, managing and caching distributed set-
tings, tracking and load balancing endpoints, as well as several backup and restore
tasks.

• Improved integration with SharePoint—these services plug their management
UI into the SharePoint Service Management page, thereby providing a common
experience for administrators. In addition, service developers can build their own
administrative pages to manage their services and host them using SharePoint
Central Administration.

• Integration with Windows Communication Foundation—the Windows Com-
munication Foundation (WCF) service model addresses communication between
client and service.

• Round Robin Load Balancing—SharePoint provides a round-robin load bal-
ancer implementation, which can be enhanced or replaced by third-party devel-
opers as necessary.

• Claims Based Identity—an external identity system is conﬁgured to give the
application everything it needs to know about the user with each request, along
with cryptographic assurance that the identity data received comes from a trusted
source.

• Backup and Restore—the Service Application Framework allows for easy inte-

gration with the SharePoint backup/restore tool.

3.11 Conclusions

This chapter presents Service Science as the discipline which studies services, and,
in particular, e-Services, relevant to the IT community. Service Science does not
prescribe particular technologies or tools to be used for developing the services,
nor does it restrict the ways a service is provided, but rather studies the common
characteristics and the most well known technologies.

8http://msdn.microsoft.com/en-us/library/ee537258(ofﬁce.14).aspx.

References

35

Service Science is an interdisciplinary discipline, focusing on services as systems
of interacting parts. A service should be seen as a complex system that involves
people, technology, and business. This being considered, service science is based
on a multitude of existing disciplines, such as computer science, economics and
human resources management.

This chapter focuses on the IT services, i.e., services offered or deployed using
IT infrastructure, and analyzes a number of topics relevant for this domain, from
service analysis, design, development and testing (Sect. 3.3), to service applications
(Sect. 3.10).

References

1. Boehm, B.W.: A spiral model of software development and enhancement. Computer 21(5),

61–72 (1988)

2. den Hertog, P.: Knowledge-intensive business services as co-producers of innovation. Interna-

tional Journal of Innovation Management 4(4) (2000)

3. Fitzsimmons, M.J., Fitzsimmons, J.A.: Service Management: Operations, Strategy, Informa-

tion Technology. McGraw Hill, New York (1997). 2nd Revised edition, October 1997

4. Kaner, C., Bach, J., Pettichord, B.: Lessons learned in software testing: a context-driven ap-

proach (2001)

5. Miles, I.: Patterns of innovation in service industries. IBM Systems Journal 47(1), 115–128

(2008)

6. Morelli, N.: Developing new product service systems (pss): methodologies and operational

tools. Journal of Cleaner Production 14(17), 1495–1501 (2006)

7. Tekes: Finnish funding agency for technology and innovation. Tekes website (2007)
8. Verberne, B.: Software Top 100: Highlights. Software Top 100 website (2008)
9. Wirtz, J., Lovelock, C.H.: Services Marketing: People, Technology, Strategy. Prentice Hall,

New York (2006)

Chapter 4
Web Services

Abstract One paradigm that changed academic and industrial perspective on how
to realize Enterprise Application Integration (EAI) and build distributed applications
is Web services. Their emergence is the result of an evolutionary process that started
with the introduction of Remote Procedure Call (RPC) and continued with TP Mon-
itors, Object Brokers and Message-Oriented Middleware. The driving concept and
innovation behind Web services is the abstraction of functionalities as services hid-
ing the technical realization in terms of hardware and software. In the end, it is the
functionality that counts for a client and not the technicalities that realize this func-
tionality. In this chapter, we provide an introduction to Web services. We look at the
most important technologies from the Web services technologies landscape. First,
the theoretical aspects of these technologies are described including their concepts,
deﬁnitions and mechanisms. Second, each of the technologies are exempliﬁed by
means of practical examples. Finally, we discuss extensions of Web services and
provide a set of exercises that should be solved by the reader interested in ﬁxing the
concepts and notion presented in this chapter.

4.1 Motivation

The Web as we know it is an enormous success. Currently, there are trillions of
pages available on the Web, and this number is rapidly increasing. The success of
the Web is due, in principle, to the underlying open, scalable approach and tech-
nologies. A closer look at the current Web shows that it is rather a static more than
a dynamic system. It is static in the sense that the applications available on the
Web cannot be easily reused in different contexts and scenarios. The Web was actu-
ally designed for interactions among applications and humans, enabling information
sharing. It provides basic support for business-to-customer (B2C) e-Commerce, and
very limited support for business-to-business (B2B) integration and Enterprise Ap-
plication Integration (EAI). Interoperability is a major challenge that the Web and
Web technologies do not support and do not address directly. In this context, the
idea of Web services was introduced as the technology that enables interoperability
and integration of business functionalities.

The ultimate vision is that a program tasked to achieve a result can use Web ser-
vices as support for its computation or processing. The program can discover Web

D. Fensel et al., Semantic Web Services,
DOI 10.1007/978-3-642-19193-0_4, © Springer-Verlag Berlin Heidelberg 2011

37

38

4 Web Services

services and invoke them fully automated. Hence, it becomes a service requester.
If the Web services have a cost attached, the program knows when to search for
cheaper services as well as all possible payment methods. Furthermore, the pro-
gram might be able to mediate any differences between its speciﬁc needs and a Web
service that almost ﬁts.

Web services connect computers and devices with each other using the Inter-
net to exchange data and combine data in new ways. They can be deﬁned as soft-
ware objects that can be assembled over the Internet using standard protocols to
perform functions or execute business processes. The key to Web services is on-the-
ﬂy software creation through the use of loosely coupled, reusable software com-
ponents. This has fundamental implications in both technical and business terms.
Software can be delivered and paid for as ﬂuid streams of services, as opposed to
packaged products. It is possible to achieve automatic, ad-hoc interoperability be-
tween systems to accomplish business tasks. Business services can be completely
decentralized and distributed over the Internet and accessed by a wide variety of
communications devices. Businesses can be released from the burden of complex,
slow and expensive software integration and focus instead on the value of their of-
ferings and mission critical tasks. The Internet will then become a global common
platform where organizations and individuals communicate with each other to carry
out various commercial activities and provide value-added services. The barriers to
providing new offerings and entering new markets will be lowered to enable access
for small and medium-sized enterprises. The dynamic enterprise and dynamic value
chains become achievable and may even be mandatory in a competitive environ-
ment.

The design of enterprise information systems has gone through several changes
in the recent years. In order to respond to the requirements of enterprises for ﬂex-
ibility and dynamism, the traditional monolithic applications have become substi-
tuted by smaller, compassable units of functionality known as services. Information
systems must be re-tailored to ﬁt this paradigm, with new applications developed
as services, and legacy systems must be updated in order to expose service inter-
faces. The drive is towards a design of information systems which adopt paradigms
of Service Oriented Computing (SOC) together with the SOA implementation and
relevant Web service technologies.

4.1.1 Service Oriented Computing (SOC)

Service Oriented Computing (SOC) is a new computing paradigm that utilizes ser-
vices as the fundamental elements for the development of rapid, low-cost and easy
integrable enterprise applications [14, 16]. One of the main goals of SOC is to en-
able the development of networks of the integrated and collaborative applications,
regardless of both the platform where applications or services run (e.g., the oper-
ating system) and programming languages used to develop them. In this paradigm,
services are autonomous, self-describing and platform-independent computational

4.1 Motivation

39

entities, which provide a uniform and ubiquitous access to information for a wide
range of computing devices (such as desktops, PDAs, or cellular phones) and soft-
ware programs across different platforms. Any piece of code and any application
component deployed on a system can be reused and transformed into a network-
available service. Since these services are based on the service orientation paradigm,
they can then be easily described, published, discovered, and dynamically assem-
bled for developing distributed and interoperable systems.

The main goal of SOC is to facilitate the integration of newly built and legacy ap-
plications, which exist both within and across organizational boundaries. SOC must
overcome and resolve heterogeneous conﬂicts due to different platforms, program-
ming languages, security ﬁrewalls, etc. The basic idea behind this orientation is to
allow applications which were developed independently (using different languages,
technologies, or platforms) to be exposed as services and then interconnect them
exploiting the Web infrastructure with respective standards such as HTTP, XML,
SOAP, WSDL and even some complex service orchestration standards like BPEL.

4.1.2 Service Oriented Architecture (SOA)

The service oriented paradigm of computation can be abstractly implemented by
the system architecture called Service Oriented Architecture (SOA) [5, 8]. The pur-
pose of this architecture is to address the requirements of loosely coupled, standard-
based, and protocol-independent distributed computing, mapping enterprise infor-
mation systems isomorphically to the overall business process ﬂow [15]. This at-
tempt is considered to be the latest development of a long series of advancements in
software engineering addressing the reuse of software components.

Historically, the ﬁrst major step of this evolution has been the development of the
concept of function. Using functions, a program is decomposed into smaller sub-
programs and writing code is focused on the idea of the application programming
interface (API). An API, practically, represents the contract to which a software
component has to commit. The second major step was the development of the con-
cept of object. An object is a basic building block which contains both data and
functions within a single encapsulated unit. With the object-oriented paradigm, the
notions of classes, inheritance and polymorphism are introduced. In this way, classes
can be viewed as a lattice. The concept of a service becomes the next evolution step
introduced with the advent of SOC and its SOA implementation.

The following Fig. 4.1 illustrates the Web Services Programming Model which
consists of three components: service consumers, service providers and service reg-
istrars. Ignoring the detailed techniques for the connection of the three components,
this model also represents the SOA basic model. A service registrar (also called
a service broker) acts as an intermediary between the provider and the consumer.
A service provider simply publishes the service. A service consumer tries to ﬁnd
services using the registrar; if it ﬁnds the desired service, it can set up a contract
with the provider in order to consume this service.

40

Fig. 4.1 Web services
programming model

4 Web Services

The fundamental logical view of services in SOA is based on the division of
service description (frequently called interface) and service implementation [15].
Service interface deﬁnes the identity of a service and its invocation logistics. Ser-
vice implementation implements the internal operations that the service is desig-
nated to do. Based on this division, service providers and services consumers are
loosely coupled. Furthermore, the services can be signiﬁcantly reused and adapted
according to certain requirements. Because service interfaces are platform indepen-
dent and implementation is transparent for the service consumers, a client from any
communication device using any computational platform, operating system and any
programming language should be capable of using the service. The two facets of the
service are distinct; they are designed and maintained as distinct items, though their
existence is highly interrelated.

Based on the service autonomy and the clean separation of service interfaces
from internal implementation, SOA provides a more ﬂexible architecture that uniﬁes
business processes by modularizing large applications into services. Furthermore,
enterprise-wide or even cross-enterprise applications can be realized by means of
services development, integration, and adaptation.

The remainder of this chapter focuses on the technical solutions available to im-

plement the Service Oriented Architecture and Web services vision.

4.2 Technical Solution

Web services are “modular, self-describing, self-contained applications that are ac-
cessible over the Internet” [11]. They can be seen as an effort to build a distributed
platform on top of the WWW, by adding a new level of functionality to the current
Web. A set of Web service technologies, most of them standardized by various stan-
dardization bodies (e.g., OASIS, W3C), provide the means for communication and
integration of Web services-based applications. Three of these technologies form
the foundation of most Web services based systems, namely: (i) WSDL [9]—an
XML description language for Web services, (ii) SOAP [19]—an XML based mes-
sage format to exchange arbitrary XML data between services and clients, and (iii)

4.2 Technical Solution

41

UDDI [4]—data model and API for Web service registries. Before we investigate
the actual technologies that are currently used to implement Web services, let us
ﬁrst deﬁne the notion of a service.

4.2.1 Deﬁning Web Services

As has been pointed out in [17], the notion of a service is semantically overloaded.
Different communities have a different understanding of what a service is. For ex-
ample, in the business community a service is seen as a business activity that often
results in intangible outcomes or beneﬁts [1], while in Computer Science the terms
service and Web service are often regarded as interchangeable to name a software
entity accessible over the Internet. In the reminder of this section, we deﬁne the high
level terminology used in this chapter. More precisely, we make a clear distinction
between the notions of a service and a Web service.

Service A service is deﬁned in [17] as a provision of value in some domain. As an
example, let us consider a user who wants to book a ﬂight from Vienna to Innsbruck
on a given date. The appropriate service provides a ﬂight ticket with the speciﬁed
constraints. Such provision is independent of how the supplier and the provider
interact, i.e., it does not matter whether the requester goes to an airline tickets ofﬁce
or uses the airline Web site to book the ﬂight. We understand the term service in the
sense given in [17], that is, as a provision of value.

Web Service A Web service is deﬁned in [17] as a computational entity accessible
over the Internet (using Web service standards and protocols). Re-analyzing the
previous example, an airline might provide a software component accessible via
Web service standards, i.e., a Web service to request the booking of a ﬂight. As
such, the Web service is an electronic means to request a service, but not the service
itself. We understand the term Web service in this sense, i.e., as a means to request
a service, described using agreed standards.

4.2.1.1 Service Properties

There are three different types of properties that can be identiﬁed for services and
Web services, namely: (i) functional, (ii) behavioral and (iii) non-functional prop-
erties. They can be brieﬂy deﬁned as follows:

• The functional description contains the formal speciﬁcation of what a service

can do.

• The behavioral description concerns how the functionality of the service can be
achieved in terms of the interaction with the service and the functionality required
from other Web services.

42

4 Web Services

Fig. 4.2 Web services usage process

• The non-functional descriptions capture constraints over the previous two types

of properties [10].

For example, considering a train booking service, invoking its functionality
(booking a train ticket) might be constrained by using a secure connection (security
as non-functional property) or by actually performing the invocation of the services
at a certain point in time (temporal availability as a non-functional property).

4.2.2 Web Service Technologies

The overall Web services usage process illustrated at the technical level is depicted
in Fig. 4.2.

The service providers register and advertise their services with an UDDI registry
by providing details such as contact information of the service provider, pointers to
services and their WSDL descriptions, etc. Once the registry is populated with ser-
vices related information, service consumers, which in most cases are developers of
service-oriented applications, could pragmatically access the registry. UDDI queries
are issued by the service consumers and potentially the UDDI registry positively an-
swers these queries. If a relevant service is found, the registry provides the service
consumer with the information needed to access the service. However, the service
consumer still needs to ﬁgure out how to actually access and invoke the service, in-
formation usually available in the WSDL description of the service. This introduces
a big overhead and generates problems when distributed applications are developed.
Keeping human intervention (i.e., software developer intervention) at minimum and
automating service related tasks could overcome the previous mentioned problem.

4.2.2.1 Web Service Description Language (WSDL)

WSDL [9] is an XML based description language for Web services. A service is de-
ﬁned as a collection of network endpoints or ports. Two levels of service descrip-
tion are identiﬁed in WSDL. First, an abstract interface level provides details about

4.2 Technical Solution

Fig. 4.3 WSDL elements

43

types, operations and interfaces of the service. Second, concrete network protocols
and endpoints specify how and where the service can be accessed. The reminder
of this section describes in detail each of the WSDL elements, using the WSDL
version 2.0 (see Listing 4.1).

At the abstract interface level, types are deﬁned in terms of XML Schemas. Types
are used to deﬁne messages which represent data being exchanged between service
providers and service invokers. Messages are grouped in operations, each operation
consisting of one or more messages. Operations specify as well the order in which
the messages are sent or received, following predeﬁned message exchange patterns
(i.e., “In-Out”, “Out-Only”, “Robust-In-Only”, “In-Optional-Out”). Finally, the in-
terface groups together more operations. The graphical representation of the WSDL
structure is represented in Fig. 4.3.

In WSDL, an operation represents a simple exchange of messages that follows
a speciﬁc message exchange pattern (MEP). The simplest of MEPs, “In-Only”, al-
lows a single application message to be sent to the service, and “Out-Only” sym-
metrically allows a single message to be sent by the service to its client. Somewhat
more useful is the “Robust-In-Only” MEP, that also allows a single incoming ap-
plication message but in case there is a problem with it, the service may reply with
a fault message. Perhaps the most common MEP is “In-Out”, which allows an in-
coming application message followed either by an outgoing application message or
an outgoing fault message. Finally, an interesting MEP commonly used in messag-
ing systems is “In-Optional-Out” where a single incoming application message may
(but does not have to) be followed either by a fault outgoing message or by a normal
outgoing message, which in turn may be followed by an incoming fault message
(i.e., the client may indicate to the service a problem with its reply).

In order to communicate with a Web service described by an abstract interface, a
client must know how the XML messages are serialized on the network and where
exactly they should be sent. In WSDL, on-the-wire message serialization is de-

4 Web Services

(cid:3)

44
(cid:2)
<?xml version="1.0" encoding="UTF−8"?>
<description xmlns="http://www.w3.org/ns/wsdl"

xmlns:tns="http://www.example.com/wsdl20sample"
xmlns:whttp="http://www.w3.org/ns/wsdl/http"
xmlns:wsoap="http://www.w3.org/ns/wsdl/soap"
targetNamespace="http://www.example.com/wsdl20sample">

<!−− Abstract types −−>

<types>

<xs:schema xmlns="http://www.example.com/wsdl20sample"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
targetNamespace="http://www.example.com/wsdl20sample">

<xs:element name="request"> ... </xs:element>
<xs:element name="response"> ... </xs:element>

</xs:schema>

</types>

<!−− Abstract interfaces −−>

<interface name="Interface1">

<fault name="Error1" element="tns:response"/>
<operation name="Opp1" pattern="http://www.w3.org/ns/wsdl/in−out">

<input messageLabel="Msg1" element="tns:request"/>
<output messageLabel="Msg2" element="tns:response"/>

</operation>

</interface>

<!−− Concrete Binding Over HTTP −−>

<binding name="HttpBinding" interface="tns:Interface1"
type="http://www.w3.org/ns/wsdl/http">
<operation ref="tns:Opp1" whttp:method="GET"/>

</binding>

<!−− Concrete Binding with SOAP−−>

<binding name="SoapBinding" interface="tns:Interface1"
type="http://www.w3.org/ns/wsdl/soap"
wsoap:protocol="http://www.w3.org/2003/05/soap/bindings/HTTP/"
wsoap:mepDefault="http://www.w3.org/2003/05/soap/mep/request−response">

<operation ref="tns:Opp1" />

</binding>

<!−− Web service offering endpoints for both the bindings−−>

<service name="Service1" interface="tns:Interface1">

<endpoint name="HttpEndpoint" binding="tns:HttpBinding" address="http://www.example.com/rest/"/>
<endpoint name="SoapEndpoint" binding="tns:SoapBinding" address="http://www.example.com/soap/"/>

</service>
</description>
(cid:4)

Listing 4.1 WSDL 2.0 Skeleton example

(cid:5)

scribed in a binding and then a service construct enumerates a number of concrete
endpoint addresses.

A binding generally follows the structure of an interface and speciﬁes the neces-
sary serialization details. The WSDL speciﬁcation contains two predeﬁned binding
speciﬁcations, one for SOAP (over HTTP) and one for plain HTTP. These bindings
specify how an abstract XML message is embedded inside a SOAP message enve-
lope or in an HTTP message, and how the message exchange patterns are realized
in SOAP or HTTP. Due to extensive use of defaults, simple bindings only need to
specify very few parameters, as in the example below. A notable exception to de-
faulting in binding are faults, as in SOAP every fault must have a so-called fault code

4.2 Technical Solution

45

with two main options, Sender or Receiver, indicating who has a problem. There is
no reasonable default possible for the fault code.

Bindings seldom need to contain details speciﬁc to a single actual physical ser-
vice, therefore in many cases they can be as reusable as interfaces, and equivalent
services by different providers only need to specify the different endpoints, sharing
the interface and binding descriptions.

The service construct in WSDL represents a single physical Web service that
implements a single interface. The Web service can be accessible at multiple end-
points, each potentially with a different binding, for example, one endpoint using an
optimized messaging protocol with no data encryption for the secure environment
of an intranet and a second endpoint using SOAP over HTTP for access from the
Internet.

4.2.2.2 Simple Object Access Protocol (SOAP)

SOAP [19] is an XML based message format to exchange arbitrary XML data. It
uses mostly HTTP/HTTPS as an underlying communication protocol. SOAP was
designed to address transport and messaging for large distributed environments. It
deﬁnes how to organize information using XML so that it can be exchanged be-
tween machines. However, SOAP is not aware of the semantics of the messages
being transmitted. From a communication point of view, SOAP is a stateless and
one-way communication protocol. The communication between two parties needs
to be encoded in SOAP and any complex communication pattern between the par-
ties involved needs to be implemented by the underlying system. There are three
important aspects that deﬁne together the SOAP protocol: (i) the message structure,
(ii) the processing model, and (iii) the protocol bindings.

Message Structure At the top level a SOAP message consists of an envelope
element where the application encodes whatever information needs to be sent. The
envelope element deﬁnes the start and the end of the message. An envelope element
contains a body that is mandatory and a header element that is optional. The header
element contains any optional attributes of the message, either at an intermediary
point or at the ultimate end point. The body element contains call and response
information, in other words, the XML data comprising the message being sent or
received. Additionally, a SOAP message that is generated on the service side might
contain a fault element in case of failure. Listing 4.2 contains a SOAP skeleton
showing the relation between the elements described above.

To illustrate how the SOAP communication between two parties is encoded, let
us consider a simple example in which a client application wants to interact with
a weather service. The service is expecting as input the city name and in return
it provides the current temperature in that city. The SOAP request is illustrated in
Listing 4.3 and the associated response in case no problems occurred during the
invocation is illustrated in Listing 4.4.

46
(cid:2)
<?xml version=1.0?> <soap:Envelope
xmlns:soap=http://www.w3c.org/2001/12/soap−envelope
soap:encodingStyle=http://www.w3c.org/2001/12/soap−encoding>
<soap:Header>
...
</soap:Header>

<soap:Body>
...
<soap:Fault>
...
</soap:Fault>
</soap:Body>
</soap:Envelope>
(cid:4)

Listing 4.2 SOAP skeleton

(cid:2)
POST /InStock HTTP/1.1 Host: www.example.org Content−Type:
application/soap+xml; charset=utf−8 Content−Length: nnn

<?xml version="1.0"?> <soap:Envelope
xmlns:soap="http://www.w3.org/2001/12/soap−envelope"
soap:encodingStyle="http://www.w3.org/2001/12/soap−encoding">

<soap:Body xmlns:m="http://www.example.org/weather">

<m:GetTemperature>

<m:CityName>Innsbruck</m:CityName>

</m:GetTemperature>

</soap:Body>

</soap:Envelope>
(cid:4)

Listing 4.3 SOAP request

(cid:2)
HTTP/1.1 200 OK Content−Type: application/soap+xml; charset=utf−8
Content−Length: nnn

<?xml version="1.0"?> <soap:Envelope
xmlns:soap="http://www.w3.org/2001/12/soap−envelope"
soap:encodingStyle="http://www.w3.org/2001/12/soap−encoding">

<soap:Body xmlns:m="http://www.example.org/services/weather">

<m:GetTemperatureResponse>

<m:Temperature>10</m:Temperature>

</m:GetTemperatureResponse>

</soap:Body>

</soap:Envelope>
(cid:4)

Listing 4.4 SOAP replay

4 Web Services

(cid:3)

(cid:5)

(cid:3)

(cid:5)

(cid:3)

(cid:5)

Processing Model The SOAP processing model deﬁnes the rules for processing
a SOAP message. More precisely, a distributed processing model is proposed, in
which the SOAP message originates at an initial SOAP sender and is sent to an ulti-
mate SOAP receiver via zero or more SOAP intermediaries. The header information
of a SOAP message plays an important role in the overall SOAP processing model,

4.2 Technical Solution

47

deﬁning what part of the message is allowed to be processed by whom. Parties in-
volved in the processing model are called SOAP nodes. SOAP deﬁnes three roles for
SOAP nodes, namely: none, next and ultimateReceiver. Within a SOAP message
any header block that was assigned to a none role should not be processed by any
SOAP nodes. A header block that was assigned to a next role should be processed
by each SOAP node along the path, excluding the initial node. A header block that
was assigned to a ultimateReceiver role must be processed only by the recipient
of the message. The processing of the header block by various SOAP nodes along
the path is done by each individual node depending on its role, and it is mandatory
if the mustUnderstand ﬂag is on. If this ﬂag is not set, SOAP nodes which can-
not understand the header blocks targeted to them could simply ignore the header
blocks.

Protocol Bindings To specify how the SOAP message is going to be transported
over the network, the protocol binding part of SOAP is used. SOAP enables ex-
change of SOAP messages using a variety of underlying protocols. A common used
protocol for SOAP binding is HTTP, but other protocols can be used as well, e.g.,
SMTP. Three transport aspects are described as part of a SOAP binding, namely:
(i) addressing that speciﬁes what an endpoint address looks like, (ii) serialization
that speciﬁes how to put XML message in on-the-wire bits and bytes, and (iii) con-
nection that speciﬁes how to send the bits to an endpoint.

4.2.2.3 Universal Description, Discovery and Integration Protocol (UDDI)

UDDI [4], on the one hand, provides a mechanism for service providers to regis-
ter their Web services and, on the other hand, for service consumers to ﬁnd them.
UDDI deﬁnes a standard data model and API for Web services registries. The data
model is used to store into registry information about businesses or service provides,
service offered by these businesses as well as technical information about these ser-
vices in form of WSDL descriptions. There are ﬁve data structure types deﬁned as
part of the data model:
• The businessEntity describes a business or service provider entity in terms of
name, description and type of business performed. For deﬁning the business type,
UDDI offers the possibility to attach business categories from predeﬁned clas-
siﬁcation hierarchies such as UNSPSC1 using the categoryBag element and a
set of identiﬁers using the identiﬁerBag element. A businessEntity is usually
providing one or more services that are linked with the businessEntity via the
businessService data structure.

Listing 4.5 exempliﬁes how a businessEntity is represented for an imaginary
Weather Company. Such a company provides, for example, a weather service
with which a client interacts by exchanging SOAP messages as exempliﬁed in
Sect. 4.2.2.2.

1http://www.unspsc.org/.

48
(cid:2)
<businessEntity businessKey="uuid:EAE4D5A8−CFF4−4501−55AD−E702126866A0"

4 Web Services

(cid:3)

operator="http://www.example.org/weather"
authorizedName="John Doe">

<name>Weather Company</name>
<description>

We provide you with weather information

</description>
<contacts>

<contact useType="general info">

<description>General Information</description>
<personName>John Doe</personName>
<phone> +(43) 444−1111 </phone>
<email>jdoe@weather.com</email>

</contact>

</contacts>

<businessServices>
...
</businessServices>

</businessEntity>
(cid:4)

Listing 4.5 UDDI businessEntity—XML representation

(cid:2)

(cid:4)

<businessServices>
<businessService serviceKey="uuid:D6F1B765−BDB3−4837−828D−8284301E5A2A"

businessKey="uuid:BA744ED0−3EE7−91D3−DC23−11E035229C64">
<name>WeatherWebService</name>
<description>A weather Web service</description>
<bindingTemplates>
...
</bindingTemplates>
<categoryBag />
</businessService
</businessServices>

Listing 4.6 UDDI businessService—XML representation

(cid:5)

(cid:3)

(cid:5)

• The businessService contains information about the service provided by a busi-
nessEntity, including name, description and information on how to access the
services as part of the bindingTemplate element.

An example of businessService element describing the Weather service intro-

duced above is presented in Listing 4.6

• The bindingTemplate provides detailed information about a service including an

entry-point address for accessing the service.

An example of bindingTemplate element associated with the Weather service

is presented in Listing 4.7.

• The tModel is the part of the data model intensively used for search. It collects

the information uniquely identifying the service speciﬁcation.

An example of tModel element associated with the Weather service is pre-

sented in Listing 4.8.

An UDDI registry can be accessed using the UDDI Registry API. This API
provides programmatic means to publish services, access and query the registry.
The methods of the API are grouped in six sets of APIs:

4.2 Technical Solution
(cid:2)

<bindingTemplate

bindingKey="uuid:D6F1B765−BDB3−4837−828D−8284301E5A2A"
serviceKey="uuid:C0E6D5A8−3E16−4f01−99DA−035229685A40">

<description xml:lang="en">SOAP binding for

weather service</description>

<accessPoint

URLType="http">http://www.example.org/weather:80/soap</accessPoint>

<tModelInstanceDetails>
<tModelInstanceInfo

tModelKey="uuid:EB1B645F−CF2F−491f−811A−4868705F5904" />

</tModelInstanceDetails>

</bindingTemplate>
</bindingTemplates>

(cid:4)

Listing 4.7 UDDI bindingTemplate—XML representation

(cid:2)
<tModel tModelKey="uuid:xyz987..."

operator="http://www.example.org/weather"
authorizedName="John Doe">
<name>WeatherInterface Port Type</name>
<description>

An interface for the Weather service

</description>
<overviewDoc>

<overviewURL>

http://www.example.org/services/weather.wsdl

</overviewURL>

</overviewDoc>

</tModel>
(cid:4)

Listing 4.8 UDDI tModel—XML representation

49

(cid:3)

(cid:5)

(cid:3)

(cid:5)

• The UDDI Inquiry API contains methods to query the registry (e.g., ﬁnd_
service, ﬁnd_business, ﬁnd_binding, etc.) and methods to retrieve detailed in-
formation about speciﬁc entities (e.g., get_serviceDetail, get_bindingDetail,
etc.)

• The UDDI Publishers API contains methods to add, modify and delete enti-
ties in the registry. Methods such as save_business, save_service, save_tModel,
etc. are used to add an modify UDDI registry entities, while methods such as
delete_business, delete_service, delete_tModel, etc. are used to remove entities
from the registry.

• The UDDI Security API contains methods to get and discard authentication
tokens that are used in communication with the registry (get_authToken, dis-
card_authToken, etc.)

• The UDDI Custody and Ownership Transfer API contains methods that allow
the transfer of ownership and structures from one publisher to another. Methods
such as get_trnasferToken and transfer_custody are part of this API.

• The UDDI Subscription API contains methods that enable the monitoring
of changes in a registry. The following methods are part of the subscription
API:get_subscriptionResult, get_subscriptions, save_subscriptions, etc.

• The UDDI Replication API contains methods that enable the replication of in-
formation between registries, so that different registries can be kept synchronized.

50

4 Web Services

4.2.2.4 Other Web Services Standards

The rest of this section provides an overview of some of the other Web services
related standards, namely WS-Addressing for communicating addressing informa-
tion between services, WS-Policy for specifying policies regarding quality of ser-
vice, both of a user and a service side, WS-Security for describing security con-
straints and requirements when interacting with services and ebXML as an alterna-
tive registry solution.

4.2.2.5 WS-Addressing

WS-Addressing [6] is a speciﬁcation of transport-neutral mechanisms that allow
Web services to communicate addressing information. The approach addresses
some of the drawbacks of SOAP, such as the lack of a standard way to specify
where a message is going, how to return a response, or where to report an error. WS-
Addressing introduces two important constructs: endpoint references and message
information headers. The endpoint reference provides pointers to where the Web
service messages can be targeted. It consists of an address (a URI) and a set of
reference properties that uniquely identify the target instance. The message infor-
mation header conveys end-to-end message characteristics including addressing for
source and destination endpoints as well as message identity. One problem tack-
led by WS-Addressing is how to direct requests coming from a speciﬁc client to a
speciﬁc instance of the service handling the interaction with that client.

An example of an endpoint reference in WS-Addressing is provided in List-

ing 4.9.

In this example, the wsa:Address element contains the address that represents
the location of the service and identiﬁes it. The following element wsa:Reference
Properties contains the resource to which the service refers and the wsa:Reference
Parameters speciﬁes additional information about the resource(s) used by the ser-
vice that facilitates the interaction.

The example in Listing 4.10 demonstrates the usage of message information

header as part of the SOAP message following WS-Addressing speciﬁcation.

(cid:2)
<wsa:EndpointReference>

<wsa:Address>

http://www.example.com/services/weather

</wsa:Address>
<wsa:ReferenceProperties>

<tns:resourceID>InsbruckData42</tns:resourceID>

</wsa:ReferenceProperties>
<wsa:ReferenceParameters>

<tns:expires>32000</tns:expires>

</wsa:ReferenceParameters>

</wsa:EndpointReference>
(cid:4)

Listing 4.9 WS-Addressing endpoint reference

(cid:3)

(cid:5)

4.2 Technical Solution
(cid:2)
<S:Envelope xmlns:S="http://www.w3.org/2003/05/soap−envelope"

xmlns:wsa="http://schemas.xmlsoap.org/ws/2004/08/addressing">
<S:Header>

<wsa:MessageID>

uuid:6B29FC40−CA47−1067−B31D−00DD010662DA

</wsa:MessageID>
<wsa:From>

<wsa:Address>http://examples.org/client1</wsa:Address>

</wsa:From>
<wsa:ReplyTo>

<wsa:Address>http://examples.org/client1</wsa:Address>

</wsa:ReplyTo>
<wsa:To>http://examples.org/weather</wsa:To>
<wsa:Action>http://examples/weather/GetTemperature</wsa:Action>

</S:Header>
<S:Body>
...
</S:Body>
</S:Envelope>
(cid:4)

Listing 4.10 WS-Addressing example

4.2.2.6 WS-Policy

51

(cid:3)

(cid:5)

The Web Services Policy Framework (WS-Policy) [2] is a speciﬁcation that allows
advertising service providers to describe policies of Web services (on security, qual-
ity of service, etc.) and service consumers to specify their policy requirements.

The key feature of WS-Policy is its ﬂexible and extensible grammar for express-
ing the capabilities, requirements, and general characteristics of entities in an XML
Web services-based system. In this context, WS-Policy deﬁnes a base set of con-
structs that can be used and extended by other Web services speciﬁcations to de-
scribe a broad range of service requirements and capabilities.

At the core of WS-Policy stands the concept of policy expression which contains
domain-speciﬁc, Web service policy information. WS-Policy further deﬁnes a core
set of constructs to indicate how choices and/or combinations of domain-speciﬁc
policy assertions apply in a Web services environment. In the following, we shortly
describe the concepts for a policy expression and the way they are related. A policy
expression is an XML Infoset representation of a policy.

At the abstract level, a policy is a potentially empty collection of policy alterna-
tives. Alternatives are not ordered. They may differ signiﬁcantly in terms of the be-
haviors they indicate, as well as conversely, they may be very similar. In either case,
the value or suitability of an alternative is generally a function of the semantics of
assertions within the alternative, and it is therefore beyond the scope of WS-Policy.

Policy Alternative A policy alternative is a logical construct which represents a
potentially empty collection of policy assertions. The vocabulary of a policy al-
ternative is the set of all assertion types within the alternative. The vocabulary of
a policy is the set of all assertion types used in all the policy alternatives in the
policy.

Policy Assertion A policy assertion identiﬁes a behavior that is a requirement (or
capability) of a policy subject. Assertions indicate domain-speciﬁc (e.g., security,

52
(cid:2)
<wsp:Policy>
<wsp:ExactlyOne>
<wsse:SecurityToken>
<wsse:TokenType>wsse:Kerberosv5TGT</wsse:TokenType>
</wsse:SecurityToken>
<wsse:SecurityToken>
<wsse:TokenType>wsse:X509v3</wsse:TokenType>
</wsse:SecurityToken>
</wsp:ExactlyOne>
</wsp:Policy>
(cid:4)

Listing 4.11 WS-Policy example

4 Web Services

(cid:3)

(cid:5)

transactions) semantics and are expected to be deﬁned in separate, domain-speciﬁc
speciﬁcations. Assertions are strongly typed by the domain authors that deﬁne
them.

Additionally, WS-Policy deﬁnes the following terms:

• Policy Assertion Type

A policy assertion type represents a class of policy assertions and implies a
schema for the assertion and assertion-speciﬁc semantics.

• Policy Assertion Parameter

A policy assertion parameter qualiﬁes the behavior indicated by a policy asser-
tion.

• Policy Vocabulary

The policy vocabulary of a policy is the set of all policy assertion types used in
the policy.
• Policy Subject

A policy subject is an entity (e.g., an endpoint, message, resource, interaction)
with which a policy can be associated.

• Policy Scope

A policy scope is a collection of policy subjects to which a policy may apply.

• Policy Attachment

A policy attachment is a mechanism for associating policy with one or more pol-
icy scopes.

Listing 4.11 provides an example of a policy requiring the use of Kerberos or

X509 security tokens.

Syntactically, WS-Policy offers several ways of expressing policies, but all are
equivalent to a single set of alternatives containing only atomic assertions. WS-
Policy Framework is accompanied by further speciﬁcations:
• WS Policy Attachment [3] speciﬁes two general-purpose mechanisms for asso-

ciating Policies with one or more policy subjects.

• Web Services Security Policy Language [12] speciﬁes policy assertions regard-

ing the use of Web Services Security [13].

• WS Policy Assertions [7] deﬁnes several general-use policy assertions.

WS-Policy is meant for expressing the capabilities, requirements, and general
characteristics of entities in an XML Web services-based system [2]. WSDL de-

4.2 Technical Solution

53

scriptions of Web services are an example of the entities to which policies are at-
tached even while they would ﬁt the above deﬁnition; this split indicates that not all
capabilities, requirements and general characteristics qualify as policies.

4.2.2.7 WS-Security

As mentioned in Sect. 4.1, Web services technologies were introduced to support
interoperability and integration at enterprises level. Solutions at this level are not
completed without considering features such as security of transactions. To address
the security requirements in the Web services world, a new standard, called WS-
Security, was introduced in 2004 by OASIS.2 WS-Security [13] is a communica-
tions protocol providing the means for applying security to Web services. The pro-
tocol contains speciﬁcations on how integrity and conﬁdentiality can be enforced on
Web services messaging.

More precisely, WS-Security is an extension of SOAP to support secure commu-
nication between Web services. From a implementation point of view, WS-Security
deﬁnes a SOAP header block, called Security, where security information should
be included. As part of the same header block, WS-Security constructs can be used
to specify which of the SOAP nodes is supposed to process the security information.
WS-Security deﬁnes a set of security tokens that can be attached to messages.
The set of security tokens include: (i) UsernameToken used to provide user name
and password information, (ii) BinarySecurityToken used to include security cer-
tiﬁcates and keys, and (iii) XML Token used to include rules and processes for spe-
ciﬁc XML-based security token formats. An example of WS-Security speciﬁcation,
taken from the WS-Security speciﬁcation document, is provided in Listing 4.12.

In the above example, the wsse:Security element contains security information
for the intended recipient. A custom token is associated with the message. The
ds:Signature element is used to specify a digital signature that ensures the in-
tegrity of the signed elements. Within the ds:Signature element one can specify
what is being signed and the type of canonicalization being used. The elements
being signed and the way to digest them are speciﬁed using the ds:Reference. In
this case only, the message body is signed. The signature value is declared in the
ds:SignatureValue element. The ds:KeyInfo element provides information, partial
or complete, as to where to ﬁnd the security token associated with this signature.
The rest of the message contains the body of the message.

4.2.2.8 ebXML

An ebXML registry3 is an information system that securely manages any content
type and the standardized metadata that describes it. It provides a set of services

2http://www.oasis-open.org/home/index.php.
3www.ebxml.org.

54
(cid:2)
<?xml version="1.0" encoding="utf−8"?>

<S11:Envelope xmlns:S11="..." xmlns:wsse="..." xmlns:wsu="..."
xmlns:ds="...">
<S11:Header>

<wsse:Security xmlns:wsse="...">
<xxx:CustomToken wsu:Id="MyID"

xmlns:xxx="http://fabrikam123/token">
FHUIORv...

</xxx:CustomToken>
<ds:Signature>

<ds:SignedInfo>

<ds:CanonicalizationMethod

Algorithm="http://www.w3.org/2001/10/xml−exc−c14n#"/>

<ds:SignatureMethod

Algorithm="http://www.w3.org/2000/09/xmldsig#hmac−sha1"/>

<ds:Reference URI="#MsgBody">

<ds:DigestMethod

Algorithm="http://www.w3.org/2000/09/xmldsig#sha1"/>

<ds:DigestValue>LyLsF0Pi4wPU...</ds:DigestValue>

</ds:Reference>

</ds:SignedInfo>
<ds:SignatureValue>DJbchm5gK...</ds:SignatureValue>
<ds:KeyInfo>

<wsse:SecurityTokenReference>

<wsse:Reference URI="#MyID"/>

</wsse:SecurityTokenReference>

</ds:KeyInfo>

</ds:Signature>
</wsse:Security>

</S11:Header>
<S11:Body wsu:Id="MsgBody">

<tru:StockSymbol xmlns:tru="http://fabrikam123.com/payloads">

QQQ

</tru:StockSymbol>

</S11:Body>
</S11:Envelope>

(cid:4)

Listing 4.12 WS-Security example

4 Web Services

(cid:3)

(cid:5)

that enable sharing of content and metadata between organizational entities in a fed-
erated environment. An ebXML Registry may be deployed within an application
server, a Web server, or some other service container. The registry may be avail-
able to clients as a public, semi-public, or private Web site. The ebXML Registry
thus provides a stable store where submitted information is made persistent. Such
information is used to facilitate business to business relationships and transactions.
In this context, submitted content for an ebXML Registry includes, but is not
limited to, XML schema and documents, process descriptions, ebXML core com-
ponents, context descriptions, UML models, information about organizations, and
software components.

The ebXML Registry Information Model (RIM) speciﬁcation deﬁnes the types
of metadata and content that can be stored in an ebXML Registry. The companion
document ebXML Registry Services and Protocols (RS) deﬁnes the services pro-
vided by an ebXML Registry and the protocols used by clients of the registry to
interact with these services.

According to the RIM speciﬁcation, an ebXML Registry is capable of storing
any type of electronic content such as XML documents, text documents, images,

4.3 Illustration by a Larger Example

55

Fig. 4.4 Virtual travel agency scenario overview

sound and video. Instances of such content are referred to as a Repository Items.
Repository Items are stored in a content repository provided by the ebXML Reg-
istry. In addition to the Repository Items, an ebXML Registry is also capable of
storing standardized metadata that may be used to further describe the Repository
Items. Instances of such metadata are referred to as a Registry Objects, or one of
its sub-types. Registry Objects are stored in the registry provided by the ebXML
Registry.

Although a few industry groups have endorsed ebXML Registry, the vendor com-

munity has essentially ignored this standard.

4.3 Illustration by a Larger Example

To illustrate how the Web service technologies described in the previous sections
can be used to implement a distributed application following SOA principles, let us
consider the following scenario based on the scenario introduced in [18].

Imagine a “Virtual Traveling Agency” (VTA) which is an end user service pro-
viding eTourism services to customers. These services can cover all kinds of infor-
mation services concerned with tourism—from information about events and sights
in an area to services that support online booking of ﬂights, hotels, car rentals, etc.
Such VTAs are already in existence; currently those portals are accessible via html
sites. The partners of the VTAs are integrated via conventional B2B integration. In
a nutshell, the VTA application provides the following functionality: the customers
use the VTA service as the entry point for their requests. These end-user services
are aggregated by the VTA by invoking and combining Web services offered by sev-
eral tourism service providers. To facilitate this, there can be a so-called “umbrella”
contract between the service providers and the VTA for regulating usage and al-
lowance of the Web services. Figure 4.4 gives an overview of Virtual Travel Agency
scenario.

56

4 Web Services

As depicted in Fig. 4.4, there are three actors involved in the overall scenario:
(i) the customer representing the end-user that requests a service provider by the
VTA, (ii) the tourism service provider representing a commercial company that
provides speciﬁc tourism services, and (iii) the VTA representing the entity that pro-
vides tourism services to customers by aggregating the separate services provided
by the single Service Providers.

Let us consider an imaginary hotel company, called “The Blue Hotel”, that allows
its clients to check rooms availability using the “BlueHotelService” Web service.
The WSDL representation of this service is available in Listing 4.13.

Once the “BlueHotelService” is set-up, the Blue Hotel company needs to register
the service with an UDDI registry. In this way, potential clients can query the reg-
istry and ﬁnd relevant information about the service. As described in Sect. 4.2.2.3,
the UDDI registry contains a set of data structures dedicated to “BlueHotelService”,
once this service is registered with the registry.

The businessEntity for the “Blue Hotel” company is depicted in Listing 4.14.
Listing 4.15 contains the businessService description for the “BlueHotelSer-

vice” available in the UDDI registry.

The bindingTemplate element associated with the Blue Hotel service is pre-

sented in Listing 4.16.

The tModel element associated with the Blue Hotel service is presented in List-

ing 4.17.

In the following listings, we show how the client can interact with the “BlueHo-
telService”. A potential client for this scenario is the VTA application. The com-
munication between the VTA application and the Blue Hotel Service is done using
SOAP messages. A simple interaction between VTA and the Blue Hotel Service in-
cludes issuing a request for checking the availability of a speciﬁc type of room for a
given time period interval and a response generated by the Blue Hotel Service con-
taining information about the room type, rate type and the actual rate for the room.
Listing 4.18 contains the request of the VTA application and Listing 4.19 contains
the response of the Blue Hotel Service.

4.4 Summary

This chapter discussed the basics of Web service technologies. It started ﬁrst by in-
troducing the paradigms that are gaining more and more momentum in the academia
and industry, namely Service Oriented Computing and Service Oriented Architec-
tures. They are centered around the notion of service and are a new way of designing
distributed applications, supporting interoperability and integration on a large scale.
We have ﬁrst introduced deﬁnitions of concepts and notions used in the Web service
domain. One important distinction we made was between a service that represents
a provision of value in some domain, and a Web service, that is, a computation en-
tity accessible over the Internet. We further discussed in details the three core pillar
technologies for Web services: WSDL, SOAP and UDDI.

4.4 Summary
(cid:2)
<?xml version="1.0" encoding="utf−8" ?>
<description

xmlns="http://www.w3.org/ns/wsdl"
targetNamespace= "http://www.bluehotel.com/wsdl/BlueHotelService"
xmlns:tns= "http://www.bluehotel.com/wsdl/BlueHotelService"
xmlns:bhns = "http://www.bluehotel.com/schemas/BlueHotelService"
xmlns:wsoap= "http://www.w3.org/ns/wsdl/soap"
xmlns:soap="http://www.w3.org/2003/05/soap−envelope"
xmlns:wsdlx= "http://www.w3.org/ns/wsdl−extensions">

<documentation>

This document describes the Blue Hotel Web service.

</documentation>

<types>

<xs:schema

xmlns:xs="http://www.w3.org/2001/XMLSchema"
targetNamespace="http://www.bluehotel.com/schemas/BlueHotelService"
xmlns="http://www.bluehotel.com/schemas/BlueHotelService">

<xs:element name="checkAvailability" type="tCheckAvailability"/>
<xs:complexType>
<xs:sequence>

<xs:element name="checkInDate" type="xs:date"/>
<xs:element name="checkOutDate" type="xs:date"/>
<xs:element name="roomType" type="xs:string"/>

</xs:sequence>
</xs:complexType>
</xs:element>

<xs:element name="checkAvailabilityResponse"

type="tCheckAvailabilityResponse"/>

<xs:complexType>
<xs:sequence>

<xs:element name="roomType" type="xs:string"/>
<xs:element name="rateType" type="xs:string"/>
<xs:element name="rate" type="xs:double"/>

</xs:sequence>
</xs:complexType>
</xs:element>

<xs:element name="invalidDataError" type="xs:string"/>

</xs:schema>

</types>

<interface name = "BlueServiceInterface" >

<fault name = "invalidDataFault"

element = "bhns:invalidDataError"/>

(cid:4)

Listing 4.13 WSDL description of BlueHotelService

57

(cid:3)

(cid:5)

As presented in the chapter, the language used to describe Web services is
WSDL, including the type systems used in interface deﬁnitions, the messages ex-
changes by a service, the operations it exposes, and the binding to the actual pro-
tocol to be used for invocation. SOAP, on the other hand, can be seen as the com-
munication/messaging protocol for Web services. SOAP speciﬁes a standard way
to encode messages transmitted between Web services. It can use different trans-
port protocols, such as HTTP or SMTP, that are speciﬁed as bindings. Finally, we
have discussed UDDI as the discovery approach for Web services. UDDI registry

58
(cid:2)

4 Web Services

(cid:3)

<operation name="opCheckAvailability"

pattern="http://www.w3.org/ns/wsdl/in−out"
style="http://www.w3.org/ns/wsdl/style/iri"
wsdlx:safe = "true">
<input messageLabel="In"

element="bhns:checkAvailability" />

<output messageLabel="Out"

element="bhns:checkAvailabilityResponse" />
<outfault ref="tns:invalidDataFault" messageLabel="Out"/>

</operation>

</interface>

<binding name="BlueServiceSOAPBinding"
interface="tns:BlueServiceInterface"
type="http://www.w3.org/ns/wsdl/soap"
wsoap:protocol="http://www.w3.org/2003/05/soap/bindings/HTTP/">

<fault ref="tns:invalidDataFault"
wsoap:code="soap:Sender"/>

<operation ref="tns:opCheckAvailability"

wsoap:mep="http://www.w3.org/2003/05/soap/mep/soap−response"/>

</binding>

<service name="BlueService"

interface="tns:BlueServiceInterface">

<endpoint name="reservationEndpoint"

binding="tns:BlueServiceSOAPBinding"
address ="http://www.bluehotel.com/BlueService"/>

</service>

</description>
(cid:4)

Listing 4.13 (Continued)

(cid:2)
<businessEntity businessKey="uuid:3AE4D5A8−CFF4−4501−55AD−E702126866A0"

operator="http://www.bluehotel.com/"
authorizedName="George Blue">

<name>Blue Hotel</name>
<description>

The Blue Hotel, one of the best in town

</description>
<contacts>

<contact useType="general info">

<description>General Information</description>
<personName>George Blue</personName>
<phone> +(43) 555−222 </phone>
<email>gblue@bluehotel.com</email>

</contact>

</contacts>

<businessServices>
...
</businessServices>

</businessEntity>
(cid:4)

Listing 4.14 Blue Hotel UDDI businessEntity—XML representation

(cid:5)

(cid:3)

(cid:5)

4.4 Summary
(cid:2)

<businessServices>
<businessService serviceKey="uuid:36F1B765−BDB3−4837−828D−8284301E5A2A"

businessKey="uuid:3A744ED0−3EE7−91D3−DC23−11E035229C64">
<name>BlueHotelService</name>
<description>The Blue Hotel Web service</description>
<bindingTemplates>
...
</bindingTemplates>
<categoryBag />
</businessService
</businessServices>

(cid:4)

Listing 4.15 Blue Hotel UDDI businessService—XML representation

(cid:2)

<bindingTemplate

bindingKey="uuid:36F1B765−BDB3−4837−828D−8284301E5A2A"
serviceKey="uuid:40E6D5A8−3E16−4f01−99DA−035229685A40">

<description xml:lang="en">SOAP binding for

Blue Hotel service</description>
<accessPoint

URLType="http">http://www.bluehotel.com/hotel:80/soap</accessPoint>

<tModelInstanceDetails>
<tModelInstanceInfo

tModelKey="uuid:AE1B645F−CF2F−491f−811A−4868705F5904" />

</tModelInstanceDetails>

</bindingTemplate>
</bindingTemplates>

(cid:4)

Listing 4.16 Blue Hotel UDDI bindingTemplate—XML representation

(cid:2)
<tModel tModelKey="uddi:WE1B6Q5F−CF2F−491f−811A−4868705F5904"

operator="http://www.bluehotel.com/hotel"
authorizedName="George Blue">
<name>BlueHotelInterface Port Type</name>
<description>

An interface for the Blue Hotel service

</description>
<overviewDoc>

<overviewURL>

http://www.bluehotel.com/services/BlueHotelService.wsdl

</overviewURL>

</overviewDoc>

</tModel>
(cid:4)

Listing 4.17 Blue Hotel UDDI tModel—XML representation

59

(cid:3)

(cid:5)

(cid:3)

(cid:5)

(cid:3)

(cid:5)

deﬁnes the structure of a Web services registry and APIs to access, publish, query
and modify registry entities.

The last part of the chapter presented other important Web services standards that
are used to describe and handle various other aspects of Web services, including
WS-Addressing for communicating addressing information between services, WS-
Policy for specifying policies regarding quality of service, both on the user and
service side, WS-Security for describing security constraints and requirements when
interacting with services and ebXML as an alternative registry solution.

60
(cid:2)
POST /InStock HTTP/1.1 Host: www.example.org Content−Type:
application/soap+xml; charset=utf−8 Content−Length: nnn

<?xml version="1.0"?> <soap:Envelope
xmlns:soap="http://www.w3.org/2001/12/soap−envelope"
soap:encodingStyle="http://www.w3.org/2001/12/soap−encoding">

<soap:Body xmlns:bhns= "http://www.bluehotel.com/wsdl/BlueHotelService">

<bhns:checkAvailability>

<bhns:checkInDate>2009−03−24</bhns:checkInDate>
<bhns:checkOutDate>2009−03−30</bhns:checkOutDate>
<bhns:roomType>Single</bhns:roomType>

</bhns:checkAvailability>

</soap:Body>

</soap:Envelope>
(cid:4)

Listing 4.18 SOAP request

(cid:2)
HTTP/1.1 200 OK Content−Type: application/soap+xml; charset=utf−8
Content−Length: nnn

<?xml version="1.0"?> <soap:Envelope
xmlns:soap="http://www.w3.org/2001/12/soap−envelope"
soap:encodingStyle="http://www.w3.org/2001/12/soap−encoding">

<soap:Body xmlns:bhns= "http://www.bluehotel.com/wsdl/BlueHotelService">

<bhns:checkAvailabilityResponse>

<bhns:roomType>Single</bhns:roomType>
<bhns:rateType>Discount</bhns:rateType>
<bhns:rate>150.50</bhns:rate>
</bhns:checkAvailabilityResponse>

</soap:Body>

</soap:Envelope>
(cid:4)

Listing 4.19 SOAP replay

4.5 Exercises

4 Web Services

(cid:3)

(cid:5)

(cid:3)

(cid:5)

Exercise 1 Complete the WSDL ﬁle from Listing 4.20 in a way that the operations
it provides correspond to the following procedure calls:
• ﬂoat add(ﬂoat x, int y)
• boolean lessThan(int a, int b)
• String trim(String s)

The service is available at the following endpoint address: http://www.swsbook.

com/theService

Exercise 2 Given the WSDL ﬁle depicted in Listing 4.21 (http://www.webservicex.
net/stockquote.asmx?WSDL) for a Stock Quote Web service, design a SOAP re-
quest and a SOAP response for the GetQuote operation in the StockQuoteSoap port
type.

Exercise 3 Consider a bus transportation company as one company that provides
tourism services as part of the VTA scenario introduced in Sect. 4.3. Design a

4.5 Exercises

(cid:2)

<?xml version="1.0" encoding="UTF−8"?>
<deﬁnitions name="CompService" targetNamespace="urn:Foo"
xmlns:tns="urn:Foo"

xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">

<types/>
<message name="\−\−_____________________">
<part name="parameter_1" type="xsd:integer"/>
<part name="parameter_2" type="_______________"/>

</message>
<message name="_____________________">

<part name="par_1" type="_______________"/>
<part name="par_2" type="_______________"/>

</message>
<message name="_________________">

<part name="echoRequestIn" type="_______________"/>

</message>
<message name="_________________">

<part name="resultdiv" type="_______________"/>

</message>
<message name="_________________">

<part name="resultmul" type="_______________"/>

</message>
<message name="_________________">

<part name="resultecho" type="_______________"/>

</message>
<portType name="CompIF">

<operation name="div"

parameterOrder="\−\−________________________">

<input message="__________________________"/>
<output message="_________________________"/>

</operation>
<operation name="mul" parameterOrder="________________________">

<input message="__________________________"/>
<output message="_________________________"/>

</operation>
<operation name="echo">

<input message="__________________________"/>
<output message="_________________________"/>

</operation>

</portType>
<binding name="CompIFBinding" type="tns:CompIF">

<operation name="mul">

<input>

<soap:body

encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
use="encoded" namespace="urn:Foo"/>

</input>
<output>

<soap:body

encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
use="encoded" namespace="urn:Foo"/>

</output>
<soap:operation soapAction=""/>

</operation>

{\ldots} <!−−−− other bindings skipped for space reasons −−> {\ldots}

</operation>
<soap:binding transport="http://schemas.xmlsoap.org/soap/http"

(cid:4)

Listing 4.20 Web service—WSDL

61

(cid:3)

(cid:5)

62
(cid:2)

style="rpc"/>

</binding>
<service name="CompService">

<port name="CompIFPort" binding="tns:CompIFBinding">

<soap:address location="__________________________________"/>

</port>
</service>
</deﬁnitions>
(cid:4)

Listing 4.20 (Continued)

(cid:2)
<?xml version="1.0" encoding="utf−8"?>
<wsdl:deﬁnitions xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:s="http://www.w3.org/2001/XMLSchema"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:tns="http://www.webserviceX.NET/"
xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/"
xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
targetNamespace="http://www.webserviceX.NET/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
<wsdl:types>

<s:schema elementFormDefault="qualiﬁed"

targetNamespace="http://www.webserviceX.NET/">

<s:element name="GetQuote">

<s:complexType>
<s:sequence>

<s:element minOccurs="0" maxOccurs="1" name="symbol" type="s:string" />

</s:sequence>
</s:complexType>

</s:element>
<s:element name="GetQuoteResponse">

<s:complexType>
<s:sequence>

<s:element minOccurs="0" maxOccurs="1" name="GetQuoteResult"

type="s:string" />

</s:sequence>
</s:complexType>

</s:element>
<s:element name="string" nillable="true" type="s:string" />
</s:schema>

</wsdl:types>
<wsdl:message name="GetQuoteSoapIn">

<wsdl:part name="parameters" element="tns:GetQuote" />

</wsdl:message>
<wsdl:message name="GetQuoteSoapOut">

<wsdl:part name="parameters" element="tns:GetQuoteResponse" />

</wsdl:message>
<wsdl:message name="GetQuoteHttpGetIn">
<wsdl:part name="symbol" type="s:string" />

</wsdl:message>
<wsdl:message name="GetQuoteHttpGetOut">

<wsdl:part name="Body" element="tns:string" />

</wsdl:message>
<wsdl:message name="GetQuoteHttpPostIn">
<wsdl:part name="symbol" type="s:string" />

</wsdl:message>
<wsdl:message name="GetQuoteHttpPostOut">
<wsdl:part name="Body" element="tns:string" />
</wsdl:message>

(cid:4)

Listing 4.21 Stock Quote Web service—WSDL

4 Web Services

(cid:3)

(cid:5)

(cid:3)

(cid:5)

4.5 Exercises

(cid:2)

<wsdl:portType name="StockQuoteSoap">
<wsdl:operation name="GetQuote">
<documentation xmlns="http://schemas.xmlsoap.org/wsdl/">Get Stock quote for a

company
Symbol</documentation>

<wsdl:input message="tns:GetQuoteSoapIn" />
<wsdl:output message="tns:GetQuoteSoapOut" />
</wsdl:operation>
</wsdl:portType>
<wsdl:portType name="StockQuoteHttpGet">
<wsdl:operation name="GetQuote">
<documentation xmlns="http://schemas.xmlsoap.org/wsdl/">Get Stock quote for a

company
Symbol</documentation>

<wsdl:input message="tns:GetQuoteHttpGetIn" />
<wsdl:output message="tns:GetQuoteHttpGetOut" />
</wsdl:operation>
</wsdl:portType>
<wsdl:portType name="StockQuoteHttpPost">
<wsdl:operation name="GetQuote">
<documentation xmlns="http://schemas.xmlsoap.org/wsdl/">Get Stock quote for a

company
Symbol</documentation>

<wsdl:input message="tns:GetQuoteHttpPostIn" />
<wsdl:output message="tns:GetQuoteHttpPostOut" />
</wsdl:operation>
</wsdl:portType>
<wsdl:binding name="StockQuoteSoap" type="tns:StockQuoteSoap">
<soap:binding transport="http://schemas.xmlsoap.org/soap/http"

style="document" />

<wsdl:operation name="GetQuote">
<soap:operation soapAction="http://www.webserviceX.NET/GetQuote"

style="document" />
<wsdl:input>
<soap:body use="literal" />
</wsdl:input>
<wsdl:output>
<soap:body use="literal" />
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
<wsdl:binding name="StockQuoteHttpGet" type="tns:StockQuoteHttpGet">
<http:binding verb="GET" />
<wsdl:operation name="GetQuote">
<http:operation location="/GetQuote" />
<wsdl:input>
<http:urlEncoded />
</wsdl:input>
<wsdl:output>
<mime:mimeXml part="Body" />
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
<wsdl:binding name="StockQuoteHttpPost" type="tns:StockQuoteHttpPost">
<http:binding verb="POST" />
<wsdl:operation name="GetQuote">
<http:operation location="/GetQuote" />
<wsdl:input>
<mime:content type="application/x−www−form−urlencoded" />
</wsdl:input>
<wsdl:output>

(cid:4)

Listing 4.21 (Continued)

63

(cid:3)

(cid:5)

64
(cid:2)

4 Web Services

(cid:3)

<mime:mimeXml part="Body" />
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
<wsdl:service name="StockQuote">
<wsdl:port name="StockQuoteSoap" binding="tns:StockQuoteSoap">
<soap:address location="http://www.webservicex.net/stockquote.asmx" />
</wsdl:port>
<wsdl:port name="StockQuoteHttpGet" binding="tns:StockQuoteHttpGet">
<http:address location="http://www.webservicex.net/stockquote.asmx" />
</wsdl:port>
<wsdl:port name="StockQuoteHttpPost" binding="tns:StockQuoteHttpPost">
<http:address location="http://www.webservicex.net/stockquote.asmx" />
</wsdl:port>
</wsdl:service>
</wsdl:deﬁnitions>
(cid:4)

Listing 4.21 (Continued)

(cid:5)

WSDL Web service for one of the services this company provides and explain all
its elements. The service must contain at least two operations of different type. The
binding to SOAP should be used. All the messages must have complex types.

Exercise 4 Create the XML representations of at least two of the UDDI elements
businessEntity, businessService, bindingTemplate, and tModel for a bus transporta-
tion company and its bus service. Additionally, explain why UDDI can be described
as being both a name service and a directory service, mentioning the types of en-
quiries that can be made.

References

1. Baida, Z., Gordijn, J., Omelayenko, B., Akkermans, H.: A shared service terminology for on-
line service provisioning. In: Proceedings of the Sixth International Conference on Electronic
Commerce (ICEC04) (2004)

2. Bajaj, S., Box, D., Chappell, D., Curbera, F., Daniels, G., Hallam-Baker, P., Hondo, M., Kaler,
C., Langworthy, D., Nadalin, A., Nagaratnam, N., Prafullchandra, H., von Riegen, C., Roth,
D., Schlimmer, J., Sharp, C., Shewchuk, J., Vedamuthu, A., Yalcinalp, U., Orchard, D.: Web
services policy 1.2—framework (ws-policy). Technical report (2006). http://www.w3.org/
Submission/WS-Policy/

3. Bajaj, S., Box, D., Chappell, D., Curbera, F., Daniels, G., Hallam-Baker, P., Hondo, M.,
Kaler, C., Maruyama, H., Nadalin, A., Orchard, D., Prafullchandra, H., von Riegen, C.,
Roth, D., Schlimmer, J., Sharp, C., Shewchuk, J., Vedamuthu, A., Yalcinalp, U.: Web ser-
vices policy 1.2 attachment (ws-policyattachment) (2006). http://www.w3.org/Submission/
WS-PolicyAttachment/

4. Bellwood, T.: UDDI version 2.04 API speciﬁcation. (2002). Available from http://uddi.org/

pubs/ProgrammersAPI-V2.04-Published-20020719.htm

5. Booth, D., Hugo Haas, W., McCabe, F., Newcomer, E., Champion, M., Ferris, C., Orchard,
D.: Web service architecture. W3C, Working Notes (2003/2004). http://www.w3.org/TR/
ws-arch/

6. Box, D., Christensen, E., Curbera, F., Ferguson, D., Frey, J., Hadley, M., Kaler, C., Lang-
worthy, D., Leymann, F., Lovering, B., Lucco, S., Millet, S., Mukhi, N., Nottingham,

References

65

M., Orchard, D., Shewchuk, J., Sindambiwe, E., Storey, T., Weerawarana, S., Winkler,
S.: Web services addressing (ws-addressing) (2004). http://www.w3.org/Submission/2004/
SUBM-ws-addressing-20040810/

7. Box, D., Hondo, M., Kaler, C., Maruyama, H., Nadalin, A., Nagaratnam, N., Patrick, P.,
von Riegen, C., Shewchuk, J.: Web services policy assertions language (ws-policyassertions)
(2003). http://msdn.microsoft.com/library/en-us/dnglobspec/html/ws-policyassertions.asp

8. Burbeck, S.: The

of
developerworks/library/ws-tao/

tao

e-business

services

(2000).

http://www-128.ibm.com/

9. Christensen, E., Curbera, F., Meredith, G., Weerawarana, S.: Web services description lan-

guage (WSDL) 1.1 (2001). http://www.w3.org/TR/wsdl

10. Chung, L.: Non-functional requirements for information systems design. In: Proceedings of
the 3rd International Conference on Advanced Information Systems Engineering—CAiSE’91,
7–11 April 1991, Trodheim, Norway. LNCS, pp. 5–30. Springer, Berlin (1991)

11. Curbera, F., Nagy, W.A., Weerawarana, S.: Web services: why and how. In: OOPSLA 2001

Workshop on Object-Oriented Web Services, ACM, New York (2001)

12. Della-Libera, G., Gudgin, M., Hallam-Baker, P., Hondo, M., Granqvist, H., Kaler, C.,
Maruyama, H., McIntosh, M., Nadalin, A., Nagaratnam, N., Philpott, R., Prafullchandra, H.,
Shewchuk, J., Walter, D., Zolfonoon, R.: Web services security policy language (ws-security-
policy) (2002). http://msdn.microsoft.com/ws/2002/12/ws-security-policy/

13. Nadalin, A., Kaler, C., Hallam-Baker, P., Monzillo, R.: Web services security: soap
message security 1.0 (2004). http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-
messagesecurity-1.0.pdf

14. Papazoglou, M.P.: Service-oriented computing: concepts, characteristics and directions. In:
Proceedings of the Fourth International Conference on Web Information Systems Engineering,
2003. WISE 2003 (2003)

15. Papazoglou, M.P., van den Heuvel, W.-J.: Service oriented architectures: approaches, tech-

nologies and research issues. VLDB Journal (2007)

16. Papazoglou, M.P., Traverso, P., Dustdar, S., Leymann, F.: Service-oriented computing research

roadmap (2006)

17. Preist, C.: A conceptual architecture for semantic web services. In: Proceedings of the Inter-

national Semantic Web Conference 2004 (ISWC 2004) (2004)

18. Stollberg, M., Lausen, H., Keller, U., Zaremba, M., Haller, A., Fensel, D., Kifer, M.: D3.3 v0.1
WSMO use case virtual travel agency. Working Draft D3.3v0.1, WSMO (2004). Available
from http://www.wsmo.org/2004/d3/d3.3/v0.1/
19. W3C: SOAP Version 1.2 Part 0: Primer (2003)

Chapter 5
Web2.0 and RESTful Services

Abstract
In this chapter, we discuss technologies that can be used to develop and
deploy services according to the core principles of the World Wide Web. These new
type of services are known as RESTful services. First, we introduce the theoretical
aspects of these technologies, including the main concepts, deﬁnitions and mecha-
nisms. Second, we illustrate each of them by means of practical examples. In addi-
tion, we provide an analytic comparison of RESTful and traditional WSDL-based
services which have been discussed in the previous chapter.

5.1 Motivation

The central components of the Web services technology stack, as it has been intro-
duced in the previous chapter, are WSDL [3] as an XML description language for
Web services, SOAP [12] as an XML-based message format to exchange arbitrary
XML data between services and clients, and UDDI [1] as a data model and API for
Web service registries. The technical landscape around Web services is, however,
much more scattered—spanning according to recent surveys [13] more than 80 Web
services standards, technologies and speciﬁcations. This diversity is naturally re-
lated to a high learning curve, which is required to get familiar with the overall area,
identify the most important developments, and stay up-to-date with the latest ad-
vances. Independently of these adoption issues, the WS-* technology stack does not
have much in common with the Web, despite the fact that their very name suggests
something else [5]. In other words, Web services, as they are used in most cases, do
not necessarily follow the same design principles and do not rely on the same core
formats and protocols that have lead to the undeniable success of the Web as a global
medium for communication. In a nutshell, communication on the Web is conceived
as persistent publication—an information provider makes information available by
publishing it online, and this information is then accessible to the intended readers.
In contrast, Web services are frequently geared towards targeted messaging, with
obvious consequences in terms of scalability. Two other aspects in which Web and
Web services differ are the usage of URIs and the style of interaction [7, 15]. When
sending and receiving SOAP messages, the content being exchanged is hidden in the
body of the message, and not addressed as an explicit Web resource by its own URI.
Consequently, all Web machinery involving caching and security checks is disabled,

D. Fensel et al., Semantic Web Services,
DOI 10.1007/978-3-642-19193-0_5, © Springer-Verlag Berlin Heidelberg 2011

67

68

5 Web2.0 and RESTful Services

since its use would require parsing and understanding of all possible XML dialects
that could be used to write a SOAP message. In turn, referring to the content via an
explicit URI in an HTTP request would allow the content of a message to be treated
just as any other Web resource. Moving along to the second aspect, the Web service
technology stack is oriented towards modeling stateful resources, in contradiction to
the REST (REpresentational State Transfer) architectural principles [6] underlying
the World Wide Web. Due to its stateless design, application integration and servers
for this architecture are easy to build. Every HTTP request for a URI should retrieve
the same content independent of what has happened before in other sessions, or in
the history of the current session. This allows the use of thin servers that do not
need to store, manage and retrieve the earlier session history to process the current
session. When a stateful conversation is required, this should be explicitly modeled
by different URIs. Applying these principles to Web services-based communication
means that there should not be a single URI for a Web service, or hidden ways to
model and exchange state information; instead, each potential state of a Web service
should be explicitly addressable by a different URI.

These basic ideas have lead to the emergence of a new approach to design and
build services artifacts, called RESTful services. Closely exploiting Web technolo-
gies and the REST architectural style, RESTful services make use of URI in a Web-
compliant way—URIs are used to identify resources providing a global addressing
space. In addition, the objects exchanged by the interacting services are resources
published on the Web, manipulated using a ﬁx set of operations that are classical
Web methods: GET, DELETE, POST, and PUT. By embracing the publishing prin-
ciple of the Web, RESTful services are implementing stateless interaction providing
decoupling in time, space and reference. As a positive side-effect, the scope of the
technological landscape involved is considerably narrower, including standards such
as HTTP, URI, MIME, XML, which are familiar to a larger base of potential de-
velopers. This lightweight infrastructure, where services can be built with minimal
tooling, has potentially a lower barrier for adoption than it is the case for WSDL-
based services. Following the same line of reasoning, the interaction and integration
of a RESTful service is easier than in case of WS-* technologies due to the lower
learning curve for clients and lower support demand for providers.

5.2 Technical Solution

In this section, we give an overview of the technologies that are used to realize
RESTful services. We start in Sect. 5.2.1 by describing REST, the set of principles
and the architecture style used to build large-scale distributed systems such as the
World Wide Web. Section 5.2.2 contains an overview of existing approaches to de-
scribe RESTful services. More precisely, we discuss the Web Application Descrip-
tion Language and textual descriptions for RESTful services. Section 5.2.3 intro-
duces the major approaches for data exchange between RESTful services including
JSON, a lightweight computer data interchange format and XML-based solutions.
Finally, in Sect. 5.2.4, we describe AJAX APIs, a RESTful technology that can be
used to access RESTful services.

5.2 Technical Solution

5.2.1 REST

69

REpresentational State Transfer (REST) [6] is a key design idiom that embraces a
stateless client–server architecture. REST was originally introduced as an architec-
tural style for building large-scale distributed hypermedia systems. This architec-
tural style is a rather abstract entity, whose principles have been used to explain the
excellent scalability of the HTTP 1.0 protocol and have also constrained the design
of its following version, HTTP 1.1. The term REST very often is used in conjunc-
tion with HTTP. Even though REST is mostly used in conjunction with Web, REST
is not really about the Web. REST is rather a distillation of the way the Web already
works, a set of principles that can be applied for building scalable large distributed
systems.

Conceptually, REST conceives resources as ﬁrst-class objects identiﬁed by URIs.
Resources represent the concepts that ground the conversation between a client and
a server. According to this paradigm, services are seen as well as resources avail-
able on the Web. They are manipulated through their representations. Clients can
request a speciﬁc representation of the concept from the representations the server
makes available. More precisely, in case of services, clients that want to use a ser-
vice access a particular representation of the resources representing the service by
transferring application content using a small, globally-deﬁned set of remote meth-
ods. These methods describe the action to be performed on resources. The methods
used are the well-know HTTP methods for creating, reading, updating and deleting
resources: GET, POST, DELETE, and PUT. If resources can be seen as concepts of
the conversation, the methods that we mentioned above are the verbs that the devel-
oper can use to describe the necessary actions to be performed including creation,
reading, updating, and deletion (CRUD).

One key principle of REST is stateless interaction between participants in a con-
versation. A state in this case means the state of the application/session. The state is
maintained as part of the content transferred from client to server/service and back.
This allows services to continue the conversation from the point is was left off. The
stateless approach allows to implement a characteristic that is often desirable in
distributed systems, namely decoupling, i.e., decoupling in time in this case.

5.2.2 Describing RESTful Services

Before we introduce existing approaches to describe RESTful services, let us ﬁrst
deﬁne what RESTful services are. In a nutshell, a RESTful service is a service im-
plemented using HTTP and REST principles. More precisely, a RESTful service is
a collection of Web resources that are interlinked and that can be manipulated using
standard HTTP methods (e.g., POST, GET, PUT, or DELETE). An important feature
of RESTful services is that they are data-centric rather than functionality-centric as
WS-* Web services are. One may notice the similarity in terms of principles and
technologies used between RESTful services and Web applications. However, there

70

5 Web2.0 and RESTful Services

are some clear differences between the two concepts. The most important one is that
RESTful services are intended for machine consumption, i.e., users of the services
are other services or applications, while Web applications are intended for human
consumption. RESTful services differ as well from WS-* services. The key differ-
ence is that RESTful services follow Web principles and use more Web resources.
As mentioned before, a RESTful service is a collection of Web resources. These re-
sources are identiﬁed by URIs of the form baseURI/ID. The ID can be any unique
identiﬁer. For example, if a RESTful Web service representing a collection of rooms
offered by a hotel might have the URI http://example.com/resources/hotel. If the ser-
vice uses the room number as the ID then a particular room might be present in the
collection as http://example.com/resources/hotel/123.

Although the number of RESTful services is increasing, there is currently no
standard approach to describe this kind of services. If, for WS-* Web services, the
Web Service Description Language is the de facto standard, in the RESTful service
domain all approaches to describe services are still in an early stage. To date, most
RESTful services are described using free text. More structured approaches such as
the Web Application Description Language (WADL) are currently emerging. In the
rest of this section, we give an overview of these approaches.

5.2.2.1 Web Application Description Language (WADL)

The Web Application Description Language (WADL) [11] is an XML-based lan-
guage for the description of RESTful services. It is designed to provide a machine-
processable protocol description format for use with HTTP-based Web applica-
tions, especially those using XML to communicate. So far, WADL has been poorly
adopted.

A WADL document is deﬁned using the following elements:

Application is a top level element that contains the overall description of the ser-
vice. It might contain grammars, resources, method, representation and fault ele-
ments.

Grammars acts as a container for deﬁnitions of any XML structures exchanged
during execution of the protocol described by the WADL document. Using the
sub-element include one or more structures can be included.

Resources acts as a container for the resources provided by the Web application.
Resource describes a single resource provided by the Web application. Each re-
source is identiﬁed by an URI, and the associated resources parent element. It can
contain the following sub-elements: path_variable that is used to parameterize the
identiﬁers of the parent resource, zero or more method elements, and zero or more
resource elements.

Method describes the input to and output from an HTTP protocol method that may
be applied to a resource. A method element might have two child elements: a
request element that describes the input to be included when applying an HTTP
method to a resource, and a response element that describes the output that results
from performing an HTTP method on a resource. A request element might contain
query variable elements.

5.2 Technical Solution
(cid:2)
<?xml version="1.0"?>
<application xmlns:xsi="http://www.w3.org/2001/XMLSchema−instance"
xsi:schemaLocation="http://research.sun.com/wadl/2006/10 wadl.xsd"
xmlns:tns="urn:yahoo:yn"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:yn="urn:yahoo:yn"
xmlns:ya="urn:yahoo:api"
xmlns="http://research.sun.com/wadl/2006/10">
<grammars>
<include

href="NewsSearchResponse.xsd"/>

<include

href="Error.xsd"/>

</grammars>
<resources base="http://api.search.yahoo.com/NewsSearchService/V1/">

<resource path="newsSearch">

<method name="GET" id="search">

<request>

<param name="appid" type="xsd:string"

style="query" required="true"/>

<param name="query" type="xsd:string"

style="query" required="true"/>

<param name="type" style="query" default="all">

<option value="all"/>
<option value="any"/>
<option value="phrase"/>

</param>
<param name="results" style="query" type="xsd:int" default="10"/>
<param name="start" style="query" type="xsd:int" default="1"/>
<param name="sort" style="query" default="rank">

<option value="rank"/>
<option value="date"/>

</param>
<param name="language" style="query" type="xsd:string"/>

</request>
<response>

<representation mediaType="application/xml"

element="yn:ResultSet"/>

<fault status="400" mediaType="application/xml"

element="ya:Error"/>

</response>

</method>
</resource>
</resources>

</application>
(cid:4)

Listing 5.1 WADL example

71

(cid:3)

(cid:5)

Representation describes a representation of the state of a resource, and can either
be declared globally as a child of the application element, embedded locally as a
child of a request or response element, or referenced externally.

Fault is similar to a representation element in structure, but differs in that it denotes

an error condition.

Listing 5.1 contains the WADL description of the Yahoo New Search [14].
As described earlier, the structure of a WADL description begins with an appli-
cation description and deﬁnes the XML namespaces used elsewhere in the service
description (Lines 1–8). It is followed then by a deﬁnition of the XML grammar
used by the service (Lines 9–14). In this case, NewsSearchResponse.xsd and Er-
ror.xsd are included in the description. The actual Yahoo News Search Web service

72

5 Web2.0 and RESTful Services

is described in the rest of the document. The service has a ‘search’ GET method that
requires a set of parameters (e.g., the Application ID, the query, etc.). The method
returns two possible outputs.

5.2.2.2 Textual Descriptions of RESTful Services

The descriptions of most of the RESTful services on the Web are provided as tex-
tual information encoded in HTML pages. A typical example is the Flickr RESTful
services. In this case, a set of HTML pages describe the REST API, the RESTful
service provided by Flickr. Listing 5.2 contains the Flickr documentation for one of
the Flickr API methods, namely ﬂickr.photos.getRecent. This method returns a list
of the latest public photos uploaded to Flickr.

The full description of all Flickr methods is available at [8]. The textual descrip-
tion of the service offers valuable information for the software developer that builds
application interacting with the RESTful service. Furthermore, the textual descrip-
tion available in HTML can be annotated with lightweight semantic annotations that
could enable more accurate search/discovery of RESTful services.

5.2.3 Data Exchange for RESTful Services

Data exchange is one important aspect in any communication between distinct ap-
plications. Just as any other kind of service, RESTful services can be seen as appli-
cations or software entities that can be accessed over the Internet. In this particular
case, data exchange can be done in various ways. In the following, we introduce
existing approaches to exchange data to and from RESTful services. Two major
approaches are discussed, namely JSON, a lightweight computer data interchange
format (Sect. 5.2.3.1), and XML, a general language for sharing structured data be-
tween information systems and implicitly (Sect. 5.2.3.2).

5.2.3.1 JSON

JSON [4], short for JavaScript Object Notation, is a lightweight computer data in-
terchange format, easy for humans to read and write, and, at the same time, easy for
machines to parse and generate. Another key feature of JSON is that it is a com-
pletely language-independent. Programming in JSON does not raise any challenge
for programmers experienced with the C family of languages. There are various rea-
sons for preferring JSON to XML as data exchange format instead of XML, given
the widespread adoption of the latter. First, data entities exchanged with JSON are
typed, while XML data is typeless; some of the built-in data types available in JSON
are: string, number, array and boolean. XML data, on the other hand, are all strings.
Second, JSON is lighter and faster than XML as on-the-wire data format. Third,

5.2 Technical Solution
(cid:2)

Authentication

This method does not require authentication.
Arguments

api_key (Required)

Your API application key. See here for more details.

extras (Optional)

A comma−delimited list of extra information to fetch for each returned
record. Currently supported ﬁelds are: license, date_upload, date_taken,
owner_name, icon_server, original_format, last_update, geo, tags, machine_tags,
o_dims, views, media.
per_page (Optional)

Number of photos to return per page. If this argument is omitted, it

defaults to 100. The maximum allowed value is 500.
page (Optional)

The page of results to return. If this argument is omitted, it defaults to

1.

Example Response

This method returns the standard photo list xml:

<photos page="2" pages="89" perpage="10" total="881">
<photo id="2636" owner="47058503995@N01"
secret="a123456" server="2" title="test_04"
ispublic="1" isfriend="0" isfamily="0" />
<photo id="2635" owner="47058503995@N01"
secret="b123456" server="2" title="test_03"
ispublic="0" isfriend="1" isfamily="1" />
<photo id="2633" owner="47058503995@N01"
secret="c123456" server="2" title="test_01"
ispublic="1" isfriend="0" isfamily="0" />
<photo id="2610" owner="12037949754@N01"
secret="d123456" server="2" title="00_tall"
ispublic="1" isfriend="0" isfamily="0" />

</photos>

To map <photo> elements to urls, please read the url documentation.
Error Codes

1: bad value for jump_to, must be valid photo id.
100: Invalid API Key

The API key passed was not valid or has expired.

105: Service currently unavailable

The requested service is temporarily unavailable.

111: Format "xxx" not found

The requested response format was not found.

112: Method "xxx" not found

The requested method was not found.

114: Invalid SOAP envelope

The SOAP envelope send in the request could not be parsed.

115: Invalid XML−RPC Method Call
(cid:4)

The XML−RPC request document could not be parsed.

73

(cid:3)

(cid:5)

Listing 5.2 Flickr RESTful service documentation

JSON integrates natively with JavaScript, a very popular programming language
used to develop applications on the client side; consequently, JSON objects can be
directly interpreted in JavaScript code, while XML data needs to be parsed and

74
(cid:2)
{
var weatherInnsbruck = {

"city" : "Innsbruck",
"date" : "2009−04−01",
"temperature" : 15
};

}(cid:4)

Listing 5.3 JSON object notation example

(cid:2)
<!DOCTYPE glossary PUBLIC "−//OASIS//DTD DocBook V3.1//EN">
<weatherInnbruck>
<city>Innsbruck</city>
<date>"2009−04−01"</date>
<temperature>15</temperature>
</weatherInnbruck>

(cid:4)

Listing 5.4 JSON object notation represented in XML

5 Web2.0 and RESTful Services

(cid:3)

(cid:5)

(cid:3)

(cid:5)

assigned to variables through the tedious usage of DOM APIs (Document Object
Model APIs, see the next section on XML).

JSON is built on two structures: (i) a collection of name/value pairs. In vari-
ous languages, this is realized as an object, record, structure, dictionary, hash table,
keyed list, or associative array; and (ii) an ordered list of values. In most languages,
this is realized as an array, vector, list, or sequence. The notations used to represent
the structures in JSON are conceived to be very intuitive. For example, an object
notation is an unordered set of name/value pairs. A JSON object begins with { (left
brace) and ends with } (right brace). Each name is followed by : (colon) and the
name/value pairs are separated by , (comma). An example of JSON object is pro-
vided in Listing 5.3.

This object has three properties or name/value pairs. The name is a string in
our example, city, date and temperature. The value can be any JavaScript object. In
our example, the values are ‘Innsbruck’, ‘2009-04-01’ and 15. The ﬁrst two values
are strings, but the temperature is a number. The reader might ask why the date is
represented as a string. The answer is simple. One of the sore points of JSON is the
lack of a date/time literal. This is mainly due to the absence of a date/time literal in
JavaScript, too. Most applications using JSON as a data format use either a string
or a number to express date and time values. If a string is used, you can generally
expect it to be in the ISO 8601 format.

The corresponding XML representation of the weather Innsbruck JSON object

is provided in the following listing (Listing 5.4).

A more complex example of JSON object is available in Listing 5.5. In this ex-
ample, we deﬁne an object called weatherAustria. The object has three properties
representing three regions of Austria. The values of each property are an array hold-
ing JSON objects, one for each city from the region. Each of these objects has a
structure identical to the structure of the object introduced in the previous listing
(Listing 5.3).

The same text expressed as XML is provided in Listing 5.6.

5.2 Technical Solution
(cid:2)

var weatherAustria = {

"weatherTyrol": [

{ "city" : "Innsbruck",

"date" : "2009−04−01",
"temperature" : 15},

{ "city" : "Kufstein",

"date" : "2009−04−01",
"temperature" : 16},

{ "city" : "Schwaz",

"date" : "2009−04−01",
"temperature" : 13}

],

"weatherVienna":

{ "city" : "Vienna",

"date" : "2009−04−01",
"temperature" : 16},

"weatherUpperAustria": [

{ "city" : "Linz",

"date" : "2009−04−01",
"temperature" : 14},

{ "city" : "Welz",

"date" : "2009−04−01",
"temperature" : 15}

]

}(cid:4)

Listing 5.5 JSON example expressed as text

75

(cid:3)

(cid:5)

In order to access data from a JSON object, one uses the dot notation. Taking
as example the weatherInnsbruck JSON object introduced in Listing 5.3, weath-
erInnsbruck.city returns the value of the property city of this object. Property val-
ues of complex objects are accessed in the same way. For example, the temperature
value for Innsbruck in the weatherAustria JSON object is delivered by the expres-
sion weatherAustria.weatherTyrol[0].temperature.

As discussed earlier, JSON is a text-based data exchange format. Information re-
ceived and sent to/from the client and server side is formatted as text. One can trans-
form the textual JSON representation into a JSON object using the eval() method,
which invokes the JavaScript compiler. Since JSON is a proper subset of JavaScript,
the compiler will correctly parse the text and produce an object structure. The con-
version from the object representation to the text representation of a JSON informa-
tion is achieved using the toJSONString() method applied to the JSON object.

To summarize, JSON is a lightweight, text-based data exchange format based
on a subset of the literal notation from the JavaScript programming language. It
is used in scenarios where a JavaScript implementation is available to one or both
interacting parties, for example, in the case of Ajax-style Web applications. A major
advantage of JSON is that there is virtually no learning curve for developers familiar
with JavaScript and the C-like languages. At present, the support for JSON is on
the increase, as more and more libraries for working with JSON across all major
platforms, and frameworks are being developed.

76
(cid:2)
<!DOCTYPE glossary PUBLIC "−//OASIS//DTD DocBook V3.1//EN">
<weatherAustria>
<weatherTyrol>

5 Web2.0 and RESTful Services

(cid:3)

<city>Innsbruck</city>
<date>"2009−04−01"</date>
<temperature>15</temperature>

</weatherTyrol>
<weatherTyrol>

<city>Kufstein</city>
<date>"2009−04−01"</date>
<temperature>16</temperature>

</weatherTyrol>
<weatherTyrol>

<city>Kufstein</city>
<date>"2009−04−01"</date>
<temperature>16</temperature>

</weatherTyrol>
</weatherInnbruck>
<weatherVienna>

<city>Vienna</city>
<date>"2009−04−01"</date>
<temperature>16</temperature>

</weatherVienna>
<weatherUpperAustria>
<city>Linz</city>
<date>"2009−04−01"</date>
<temperature>14</temperature>

</weatherUpperAustria>
<weatherUpperAustria>
<city>Welz</city>
<date>"2009−04−01"</date>
<temperature>15</temperature>

</weatherUpperAustria>

</weatherAustria>
(cid:4)

(cid:5)

Listing 5.6 JSON example expressed as XML

5.2.3.2 XML

XML [2], short for EXtensible Markup Language, is a general-purpose speciﬁcation
for creating custom mark-up languages. It was designed as a language for sharing
structured data on the net between information systems, for encoding documents
and for serializing data. XML began as a simpliﬁed subset of the SGML, the Stan-
dard Generalized Markup Language. SGML is the language from which HTML
stems. XML allows the user to deﬁne his/her own tags. With arbitrary SGML tags,
one can begin to indicate the meaning of particular data directly within the docu-
ment source—this was exactly what was required to successfully share structured
data across different information systems (in contrast with HTML which can be
considered relatively unstructured/less-rich due to its lack of expressivity, i.e., well-
deﬁned content). XML is simply an SGML subset tailored for the World Wide Web,
which imposes certain restrictions, such as closed tags and case sensitive names,
while still allowing for user-deﬁned tags. User-deﬁned tag names and attributes in
XML allow for easier machine-processing and at the same time XML provides a
common, structured format which allows machines to share data—a standard repre-
sentational format for documents beyond HTML including typical ofﬁce documents

5.2 Technical Solution
(cid:2)
<!DOCTYPE glossary PUBLIC "−//OASIS//DTD DocBook V3.1//EN">
<weatherVienna>
<city>Vienna</city>
<date>"2009−04−01"</date>
<temperature>17</temperature>
</weatherVienna>

(cid:4)

Listing 5.7 XML response of RESTful weather service

77

(cid:3)

(cid:5)

such as calendars and spreadsheet (which previously had no widely used standard-
ized interoperable formats).

Just like WS-* Web services, RESTful Web services can use XML as a standard
format for service input and output. Unlike the former, RESTful Web services do
not require data being transmitted to be wrapped as part of protocol speciﬁc ele-
ments (i.e., SOAP messages, in the case of WS-* services). In this way, there is no
overhead of parsing and handling complex message structures; the information is
directly exposed to the client’s parser.

XML-formatted messages are using parsing API such as DOM (Document Ob-
ject Model) or SAX (Simple API for XML). Support for DOM and SAX is available
in almost all programming languages, making it easy for clients to consume XML
messages. An example of an XML message representing the response of a RESTful
weather service is available in Listing 5.7.

There are several major concerns with respect to the usage XML for data ex-
change between RESTful services and its clients. First, XML introduces a certain
overhead due to its mark-up nature. Second, there are computational costs associated
with parsing an XML message, and using DOM for the navigation of the XML tree
model, none of which occur for JSON. Thus, JSON is recommended to be used for
passing data to/from a front-end, usually lightweight front-end. The usage of XML
as data exchange format when communicating with RESTful services is preferred
in other situations, for instance, when rich clients or other servers are involved.

5.2.4 AJAX APIs

Asynchronous JavaScript and XML, or shortly AJAX [9], is a family of Web devel-
opment technologies used to realize interactive, rich Web applications. One major
advantage of AJAX-based applications is that they can retrieve data from the server
asynchronously in the background, without interfering with the display and behavior
of the existing Web page. With AJAX one can create better, faster, and more user-
friendly Web applications by increasing the interactive animation on Web pages [9].
Several technological building blocks form the foundation of the AJAX ap-
proach. First, AJAX uses XHTML and CSS for standards-based presentation. Data
interchange and manipulation is based on XML and XSLT. AJAX makes extensive
use of the XMLHttpRequest object to asynchronously retrieve data from the server.
Using this object, the JavaScript code can communicate directly with the server,

78

5 Web2.0 and RESTful Services

trading data without reloading the entire Web page. Finally, to bind everything to-
gether, AJAX relies on JavaScript as the underlying programming language.

In the following, we brieﬂy outline the line of arguments that shows the beneﬁts
of AJAX against standard approach to implement Web application. To understand
this, let us ﬁrst recap how a standard Web application works. In the traditional model
of a Web application, the user triggers through the interface an HTTP request to a
Web server. The Web server processes the request, generates an HTML Web page
and sends it back to the client. On the server side, the ﬁrst step, namely process-
ing of the request, might take some time due, in general, to the complex business
logic being executed. The drawback in this interaction is that while the Web server
processes the request the client is left waiting, and the user experience is thus subop-
timal. AJAX tries to speciﬁcally address this part of the overall interaction process.
It introduces a third entity between the client and the server, namely the AJAX
engine. Having more parties in the interaction does not have a negative effect on
the interaction times, but rather offers the user a more dynamic interaction experi-
ence. This engine is responsible for both rendering the interface the user sees, and
communicating with the server on the user’s behalf. The communication is done
asynchronously independently of the communication with the server.

5.2.5 Examples of RESTful Services

In this section, we describe some existing RESTful services that are available on the
Web: the Atom Publishing Protocol and the Flickr API.

5.2.5.1 Atom Publishing Protocol

The Atom Publishing Protocol (AtomPub) [10] is an application-level protocol for
publishing and editing Web resources. It uses HTTP and XML as an underlying
transfer protocol and an exchange format, respectively. The data being exchanged
is speciﬁed in a XML based language called Atom Syndication Format. The speci-
ﬁcation Atom Syndication Format describes two kinds of Atom Documents: Atom
Feed Documents and Atom Entry Documents. An Atom Feed Document has as root
element the atom:feed element, and is a representation of an Atom feed, including
metadata about the feed, and some or all of the entries associated with it. An Atom
Entry Document has as root element atom:entry and represents exactly one Atom
entry, outside of the context of an Atom feed.

An example of a document in the Atom Syndication Format is available in List-

ing 5.8.

The Atom Publishing Protocol supports the creation of Web Resources and pro-
vides a means to interact with and manage collections of resources; discover and
describe collections; and interact with and manage individual resources. A high-
level overview of the AtomPub service is available in Fig. 5.1.

5.2 Technical Solution
(cid:2)
<?xml version="1.0" encoding="utf−8"?>
<feed xmlns="http://www.w3.org/2005/Atom">

<title>Example Feed</title>
<subtitle>A subtitle.</subtitle>
<link href="http://example.org/feed/" rel="self"/>
<link href="http://example.org/"/>
<updated>2009−04−05T12:45:02Z</updated>
<author>

<name>Ioan Toma</name>
<email>ioan.toma@sti2.at</email>

</author>
<id>urn:uuid:60a76c80−d399−11d9−b91C−0003939e0af6</id>

<entry>

<title>Atom−Powered Robots Run Amok</title>
<link href="http://example.org/2003/12/13/atom03"/>
<id>urn:uuid:34c5f6d5−df18−e2cc−1112−80da344efa6a</id>
<updated>2009−04−05T12:45:02Z</updated>
<summary>RESTful services are great.</summary>

</entry>

</feed>(cid:4)

Listing 5.8 Atom syndication format example

Fig. 5.1 AtomPub RESTful
service—high level overview

79

(cid:3)

(cid:5)

As illustrated in Fig. 5.1, Atom Publishing Protocol distinguishes between two
types of resources: collections and entries. The ﬁrst elements represent collections
of the later elements. An AtomPub RESTful service should provide methods to
manage both collections and entries. For collections the GET HTTP method is used
to list the entries in a collection, while POST HTTP method is used to add and entry
in the collection. In the case of entry resources, the GET HTTP method is used to
retrieve a particular entry, PUT HTTP method is used to replace and update and
entry and ﬁnally DELETE HTTP method is used to implement the delete operation
for entries.

80
(cid:2)
<rsp stat="ok">
<user id="9YYY6246@N00" nsid="9YYY6246@N00">
<username>ioantoma</username>
</user>
</rsp>(cid:4)

Listing 5.9 XML response of Flickr service

5.2.5.2 Flickr API

5 Web2.0 and RESTful Services

(cid:3)

(cid:5)

Flickr1 is a photo-sharing Web site that allows Internet users to upload and browse
photos, and add tags, comments, and annotations to these. This functionality is pro-
grammatically exposed as WS-* and RESTful services. In a nutshell, the Flickr
RESTful service is a collection of operations or methods that enable a complete
management of photos and the information related to them. Some of the supported
methods are ﬂickr.photos.addTags, ﬂickr.photos.delete, ﬂickr.contacts.getList,
ﬂickr.photos.comments.editComment. As mentioned in Sect. 5.2.2.2, the Flickr
API methods that form the Flickr RESTful service are described in textual form.

Flickr uses the HTTP methods GET and POST to implement most of the meth-
ods from the API it provides. The general way to invoke any method of the
API is to access http://api.ﬂickr.com/services/rest/?method=method&parameters,
where the last part of the URI method&parameters is replaced by a speciﬁc
method name and the associated parameters. For example, calling the Flickr method
ﬂickr.people.ﬁndByUsername with the required parameter having the value ioan-
toma will produce the result available in Listing 5.9.

One important aspect when using the Flickr RESTful service is authentication.
Users should be authenticated using the Authentication API provided by Flickr.
Once logged-in the user receives an authentication token and signature that are used
to invoke any Flickr method. In general, most ‘REST-like APIs’ have proprietary
authentication mechanisms; they deﬁne additional mandatory API keys for this pur-
pose. A closer look at the Flickr RESTful service reveals that the service does not
follow all RESTful services principles:
• The client must know all methods beforehand.
• Non-standard authentication, tokens in URIs.
• URIs with method name identify verbs (operations), not nouns (data). As an ex-
ample, instead of “DELETE URI <photo>” the Flickr API has “POST nothing
to URI <delete/photo>”.

5.3 Illustration by a Larger Example

To illustrate how RESTful services described in the previous sections can be used
to implement a distributed application, we select the same scenario that was intro-
duced in Chap. 4. We remind the reader that, in the previously mentioned scenario,

1www.ﬂickr.com.

5.3 Illustration by a Larger Example
(cid:2)
<?xml version="1.0"?>
<application xmlns:xsi="http://www.w3.org/2001/XMLSchema−instance"
xsi:schemaLocation="http://research.sun.com/wadl/wadl.xsd"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:bhns = "http://www.bluehotel.com/schemas/BlueHotelService"
xmlns="http://research.sun.com/wadl">
<grammars>

<include href="http://www.bluehotel.com/schemas/BlueHotelService.xsd/>

</grammars>

<resources base="http://www.blueHotel.com/BlueService/">
<resource uri="checkAvailability"> 18

<method href="checkAvailability"/></resource>

</resources>

<method name="GET" id="checkAvailability">

<request>

<query_variable name="checkInDate" type="xsd:date" required="true"/>
<query_variable name="checkOutDate" type="xsd:date" required="true"/>
<query_variable name="roomType" type="xsd:string" required="true"/>
<query_variable name="results" type="bhns:Response"/>

</request>

<response>
<representation mediaType="application/xml" element="bhns:Response"/>
<fault id="SearchError" status="400" mediaType="application/xml"

element="bhns:Error"/>

</response>

</method>
</application>

(cid:4)

Listing 5.10 WADL description of BlueHotelService

81

(cid:3)

(cid:5)

a ‘Virtual travel agency’ (VTA) is providing to end users eTourism services. The
agency acts as a middle man entity aggregating various tourism services provided
by other tourism providers such as booking of ﬂights, hotels, rental cars, etc. Such
tourism service providers could be the imaginary hotel company, called ‘The Blue
Hotel’, introduced in the previous chapter. The Blue Hotel allows its clients to check
for rooms availability using the ‘BlueHotelService’ Web service.

The WADL representation of this service is available in Listing 5.10.
Data exchanged between the client, in this case the VTA application, and the
RESTful service, in this case the BlueHotelService, can be represented using JSON
as explained in Sect. 5.2.3.1. A simple JSON object sent by the BlueHotelService
if requested to provide information about the availability of single rooms in a given
time interval is listed in Listing 5.11.

The corresponding XML representation of the blueHotelSingleRoom JSON ob-

ject is provided in the following listing (Listing 5.12).

A more complex JSON object might, for instance, include an array of simple
JSON objects as the one just discussed. Listing 5.13 shows an object containing the
information for all types of rooms during the same period of time.

Listing 5.14 shows the same, only in XML.

82
(cid:2)
{
var blueHotelSingleRoom = {

"startDate" : "2009−03−24",
"endDate" : "2009−03−30",
"roomType" : "Single"
"rateType" : "Discount"
"rate" : 150.50
};

}(cid:4)

5 Web2.0 and RESTful Services

(cid:3)

(cid:5)

Listing 5.11 Text representation of a simple JSON object exchanged by the BlueHotel RESTful
service

(cid:2)
<!DOCTYPE glossary PUBLIC "−//OASIS//DTD DocBook V3.1//EN">
<blueHotelSingleRoom>
<startDate>"2009−03−24"</startDate>
<endDate>"2009−03−30"</endDate>
<roomType>"Single"</roomType>
<rateType>"Discount"</rateType>
<rate>150.50</rate>
</blueHotelSingleRoom>

(cid:4)

(cid:3)

(cid:5)

Listing 5.12 XML representation of a simple JSON object exchanged by the BlueHotel RESTful
service

(cid:2)

var blueHotelRoom = {

"singleDiscount" : {

"startDate" : "2009−03−24",
"endDate" : "2009−03−30",
"roomType" : "Single"
"rateType" : "Discount"
"rate" : 150.50},

"singleNoDiscount" : {

"startDate" : "2009−03−24",
"endDate" : "2009−03−30",
"roomType" : "Single"
"rateType" : "No Discount"
"rate" : 170.00},

"doubleDiscount" : {

"startDate" : "2009−03−24",
"endDate" : "2009−03−30",
"roomType" : "Double"
"rateType" : "Discount"
"rate" : 200.00},

"doubleNoDiscount" : {

"startDate" : "2009−03−24",
"endDate" : "2009−03−30",
"roomType" : "Double"
"rateType" : "No Discount"
"rate" : 220.00}

}(cid:4)

(cid:3)

(cid:5)

Listing 5.13 Text representation of a complex JSON object exchanged by the BlueHotel RESTful
service

5.4 Summary
(cid:2)
<!DOCTYPE glossary PUBLIC "−//OASIS//DTD DocBook V3.1//EN">
<blueHotelRoom>

<singleDiscount>

<startDate>"2009−03−24"</startDate>
<endDate>"2009−03−30"</endDate>
<roomType>"Single"</roomType>
<rateType>"Discount"</rateType>
<rate>150.50</rate>

</singleDiscount>
<singleNoDiscount>

<startDate>"2009−03−24"</startDate>
<endDate>"2009−03−30"</endDate>
<roomType>"Single"</roomType>
<rateType>"No Discount"</rateType>
<rate>170.50</rate>

</singleNoDiscount>
<doubleDiscount>

<startDate>"2009−03−24"</startDate>
<endDate>"2009−03−30"</endDate>
<roomType>"Double"</roomType>
<rateType>"Discount"</rateType>
<rate>200.00</rate>

</doubleDiscount>
<doubleNoDiscount>

<startDate>"2009−03−24"</startDate>
<endDate>"2009−03−30"</endDate>
<roomType>"Double"</roomType>
<rateType>"No Discount"</rateType>
<rate>220.00</rate>

</doubleNoDiscount>

</blueHotelRoom>
(cid:4)

83

(cid:3)

(cid:5)

Listing 5.14 XML representation of a complex JSON object exchanged by the BlueHotel REST-
ful service

5.4 Summary

In this chapter, we gave an overview of an alternative approach to implement func-
tionality, namely RESTful services. We started by introducing the design principles
and core architecture style for RESTful services. Known as REST, this architec-
ture style and set of principles is the very same that turned the Web into a suc-
cessful large-scale distributed system as we know it today. Following this line of
reasoning, we have introduced, explained and exempliﬁed some of the most popular
approaches to describing and annotating RESTful functionality. The Web Applica-
tion Description Language, shortly WADL, is one of these. We have seen that this
language provides elements to describe various aspects of RESTful services. For
example, its elements capture the resources provided by the application, the meth-
ods that may be applied to a resource, representations of the resources, and error
conditions. In terms of data exchange, we have discussed JSON and XML as al-
ternative approaches. JSON is easy-to-use, reduces communication overhead, and
is natively integrated with JavaScript. XML brings in some advantages as well: ex-
tensibility and support in all popular programming languages. In the last part of the
chapter, we have discussed one RESTful services technology used to implement ap-
plications that are interacting with RESTful services, namely AJAX. It is based on

84
(cid:2)
<!DOCTYPE glossary PUBLIC "−//OASIS//DTD DocBook V3.1//EN">
<Rockbands>
<Rockband>
<Name>Beatles</Name>
<Country>England</Country>
<YearFormed>1959</YearFormed>
<Members>
<Member>Paul</Member>
<Member>John</Member>
<Member>George</Member>
<Member>Ringo</Member>
</Members>
</Rockband>
<Rockband>
<Name>Rolling Stones</Name>
<Country>England</Country>
<YearFormed>1962</YearFormed>
<Members>
<Member>Mick</Member>
<Member>Keith</Member>
<Member>Charlie</Member>
<Member>Bill</Member>
</Members>
</Rockband>
<Rockband>
<Name>Queen</Name>
<Country>England</Country>
<YearFormed>1970</YearFormed>
<Members>
<Member>Freddie</Member>
<Member>Brian</Member>
<Member>Roger</Member>
<Member>John</Member>
</Members>
</Rockband>
<Rockband>
<Name>Pink Floyd</Name>
<Country>England</Country>
<YearFormed>1965</YearFormed>
<Members>
<Member>Nick</Member>
<Member>Syd</Member>
<Member>David</Member>
<Member>Roger</Member>
<Member>Richard</Member>
</Members>
</Rockband>
</Rockbands>
(cid:4)

Listing 5.15 Rock band music info—XML representations

5 Web2.0 and RESTful Services

(cid:3)

(cid:5)

JavaScript programming for browsers providing reach interaction experience with
RESTful services for Web users.

5.5 Exercises

Exercise 1 Create a WADL ﬁle that corresponds to a business service providing
the following functionality:

85

References

• Create a new order

public Purchase OrderStatus acceptPO(PurchaseOrder order)

• Retrieve an existing order

public PurchaseOrder retrievePO(String orderID)

• Modify an existing order

public PurchaseOrder updatePO(PurchaseOrder order)

• Cancel an order already submitted

public void cancelPO(String orderID)

The service should be available at the following endpoint-address: http://www.

swsbook.com/theRESTfulService.

Exercise 2 Consider a bus transportation company being a company that provides
tourism services as part of the VTA scenario introduced in Sect. 5.3. Design a
WADL description for one of the services this company provides and explain all
its elements.

Exercise 3 Given the XML representation of a data object exchanged with a
RESTful service that provides music information in Listing 5.15 create the cor-
responding JSON textual representation.

Exercise 4 Create a JSON representation, both text and XML of the data ex-
changed between the VTA application and the bus transportation company service.
The VTA is the client, the bus transportation company is the service in this particular
interaction. The information returned by the bus transportation company includes:
the start and end city of the trip, the price for the ticket and a list of departure hours.
The bus transportation company offers trips from multiple cities in Austria.

References

1. Bellwood, T.: UDDI version 2.04 API speciﬁcation (2002). Available from http://uddi.org/

pubs/ProgrammersAPI-V2.04-Published-20020719.htm

2. Bray, T., Paoli, J., Sperberg-McQueen, C.M., Maler, E., Yergeau, F.: Extensible markup lan-
guage (xml) 1.0 (fourth edition)—origin and goals. Working draft, World Wide Web Consor-
tium (2006). Available from http://www.w3.org/TR/xml/

3. Christensen, E., Curbera, F., Meredith, G., Weerawarana, S.: Web Services Description Lan-

guage (WSDL) 1.1. (2001). http://www.w3.org/TR/wsdl

4. Crockford, D.: Json—javascript object notation. Technical report, json.org (2006). http://

www.json.org/

5. Fensel, D.: Triple-space computing: Semantic Web Services based on persistent publication
of information. In: Proc. of IFIP Int. Conf. on Intelligence in Communication Systems, pp.
43–53 (2004)

6. Fielding, R.T.: Architectural styles and the design of network-based software architec-
tures. PhD thesis, University of California, Irvine, Irvine, California (2000). http://www.
ics.uci.edu/~ﬁelding/pubs/dissertation/top.htm

7. Fielding, R.T., Taylor, R.N.: Principled design of the modern web architecture. ACM Trans-

actions on Internet Technology 2(2), 115–150 (2002). doi:10.1145/514183.514185

86

5 Web2.0 and RESTful Services

8. Flickr: Flickr services. Technical report, Flickr.com (2009). Available from http://www.ﬂickr.

com/services/api/

9. Garrett, J.J.: Ajax: A new approach to web applications. Technical report, AdaptivePath.com

(2005). Available from http://www.adaptivepath.com/ideas/essays/archives/000385.php
10. Gregorio, J., de Hora, B.: The atom publishing protocol. Rfc 5023, Internet Draft draft-ietf-

atompub-protocol-17 (2007). Available from http://tools.ietf.org/html/rfc5023

11. Hadley, M.J.: Web application description language (wadl). Working draft, Sun Microsystems

Inc. (2006). Available from https://wadl.dev.java.net/wadl20061109.pdf

12. W3C: SOAP Version 1.2 Part 0: Primer (2003)
13. Wikipedia. List of Web service speciﬁcations. http://en.wikipedia.org/wiki/WS-*
14. Yahoo!: Yahoo! web APIs. Technical report, yahoo.com (2005). http://developer.yahoo.net/
15. zur Muehlen, M., Nickerson, J.V., Swenson, K.D.: Developing web services choreography

standards—the case of rest vs. soap. Decision Support Systems 40(1), 9–29 (2005)

Chapter 6
Semantic Web

Abstract This chapter gives an overview of the Semantic Web which aims to en-
able automatic retrieval, extraction and integration of information on the World
Wide Web (WWW). Event though the current Web has become a big success, it
lacks a proper support to Web users when it comes to ﬁnding, extracting and com-
bining information. The main obstacle is that, at present, the meaning of Web con-
tent is not machine-accessible. The Semantic Web extends the current Web provid-
ing machine processable semantics to Web resources. This chapter is built around
the Semantic Web layered architecture introduced by its inventor, Tim Berners-Lee.
Each layer and language of the Semantic Web is described in terms of its major
concepts and core aspects. As part of the lower layers of the Web architecture, the
chapter introduces Unicode: the Uniform Resource Identiﬁer (URI), the Extensible
Markup Language (XML), the Document Type Deﬁnition (DTD), and the XML
Schema. The chapter then discusses languages that are built on top of the syntactic
layers introduced previously, namely the Resource Description Framework (RDF),
RDF Schema (RDFS), SPARQL, the Web Ontology Language (OWL), its new ver-
sion OWL2, and the Rule Interchange Format (RIF). The chapter then brieﬂy reports
on the other layers of the Semantic Web architecture and discusses the latest devel-
opment of the Web and Semantic Web, know as Linked Open Data.

6.1 Motivation

The current Web, or the World Wide Web (WWW), as we know it today is a big
success. It was introduced more than 15 years ago as a means for global informa-
tion sharing. Web development started even earlier with the creation of the Internet
as a means to interweave computers. Starting as a small solution for some thousand
users, the Web grew exponentially counting presently more that 1 trillion pages.1
In a nutshell, “the Web is a system of interlinked documents that run over the In-
ternet. With a Web browser, a user views Web pages that may contain text, images,
and other multimedia and navigates between them using hyperlinks”.2 Two of the

1http://googleblog.blogspot.com/2008/07/we-knew-web-was-big.html.
2http://en.wikipedia.org/wiki/World_Wide_Web.

D. Fensel et al., Semantic Web Services,
DOI 10.1007/978-3-642-19193-0_6, © Springer-Verlag Berlin Heidelberg 2011

87

88

6 Semantic Web

most representative applications that contributed to the big success of the Web are
Netscape and Google.3 The Netscape browser was the ﬁrst to provide an intuitive
and simple graphic interface that allows users to easily navigate the Web. It imme-
diately attracted a large community, making it attractive for others to present their
information on the Web. The other big Web success story is Google, the popular
search engine that is associated with the mega growth of the Web. Google indexes
more than 1 trillion pages, making it possible to access information instantly on a
global scale.

The success of the Web is based on three simple principles:

• A simple and uniform addressing schema to identify information chunks.
• A simple and uniform representation formalism to structure information chunks

allowing browsers to render them.

• A simple and uniform protocol to access information chunks.

The addressing scheme used on the Web is based on Uniform Resource Identi-
ﬁers (URIs). URIs are pointers to resources on the Web to which request methods
can be applied to generate potentially different responses. Resources are described
using a simple and uniform representation language called HyperText Markup Lan-
guage (HTML), which provides a set of pre-deﬁned tags to annotate information
sources and to deﬁne interlinks between them using URIs. Finally, the Hypertext
Transfer Protocol (HTTP) is a simple request/response protocol that can be used to
access resources on the Web. HTTP integrates nicely with the other two basic com-
ponents, namely URIs and HTML. HTTP relies on the URI naming mechanism and
provides a way to publish and retrieve resources described using HTML.

In the recent years, a new phenomenon called Web2.0 has become very popular.
Web 2.0 sites such as Facebook,4 MySpace,5 Delicious,6 YouTube,7 and LinkedIn8
have grown tremendously over the past few years, garnering increased media and
popular attention. The result of this increased awareness is that the Web has be-
come more powerfully socially linked now than ever before. Even though there are
very minor differences between Web1.0 and Web2.0 in terms of technologies used,
there are differences in emphasis between the two. With the Web 1.0 technology, a
signiﬁcant amount of software skills and investment in software was necessary to
publish information. Web 2.0 technology changed this dramatically. The four major
breakthroughs of Web 2.0 are:
• Blurring the distinction between content consumers and content providers.
• Moving from media for individuals towards media for communities.
• Blurring the distinction between service consumers and service providers.

3www.google.com.
4www.facebook.com.
5http://www.myspace.com/.
6http://delicious.com/.
7http://www.youtube.com/.
8http://www.linkedin.com/.

6.2 Technical Solution

89

• Integrating human and machine computing in a new way.

With the Web 2.0 technology the billions of people on the Web not only consume
but produce much of its content. In this way, the Web has become a true instant
communication channel of mankind on a global scale.

With all the advances of the Web1.0 and Web2.0 technologies, the current Web
still has a set of major limitations. The most visible is related to ﬁnding relevant in-
formation. Finding information on Web1.0 and Web2.0 is based on keyword search
which has a limited recall and precision. This is due, in principle, to the ambiguity of
the written natural language. For example, documents containing synonyms of the
query keywords will not be retrieved by a naive keyword-based search engine even
though they are relevant and should be included in the answer. Another shortcoming
of the keyword search is cause by homonyms from natural language. For example,
searching information on “Jaguar” will bring up pages containing information about
both “Jaguar” (the car brand) and “Jaguar” (the animal) even though the user is inter-
ested only in one of them. Other factors that have a negative inﬂuence on the recall
and precision of keyword search used on the current Web are different spelling vari-
ants and spelling mistakes. Moreover, the use of different native languages make
the cross-language retrieval of relevant document difﬁcult. Last but not least, cur-
rent search engines provide no means to specify the relationship between a resource
and a term (e.g., sell/buy).

Finding relevant information is not the only task where current approaches could
be signiﬁcantly improved. Extracting relevant information from Web pages, is an-
other one. One-size-ﬁts-all automatic solution for extracting information from Web
pages is not possible due to different formats and different syntaxes. Even on the
very same Web page, extracting relevant information proves to be a challenging task.
Current approaches for information extraction are based on wrapper technology. The
extraction of information from Web sites can be implemented using XML based
standards such as XSLT.9 Usually, the extracted information is stored as structured
data in XML format or databases. Using wrappers does not really scale because the
actual extraction of information depends on the Web site format and layout.

Last but not least, another task where current Web solutions are limited, is in
combining and reusing information on the Web. In a typical scenario, the same
information is searched for in different digital libraries. For example, when planning
to travel from Innsbruck to Rome, one could consider different alternatives such as
traveling by train, airplane or bus. Information about all these alternatives comes
from different Web sites. Furthermore, it is often the case that a combination of
partial solutions is needed to fulﬁll the initial request.

6.2 Technical Solution

To address the limitations of the current Web discussed in Sect. 6.1, a solution based
on formally describing and using the meaning of information and services has been

9http://www.w3.org/TR/xslt.

90

Fig. 6.1 Semantic Web
architecture

6 Semantic Web

proposed. The solution, called the Semantic Web, enables machines to understand
and potentially satisfy user requests, by processing the meaning or “semantics” of
information. The Semantic Web improves the current Web by increasing automation
and accuracy in various aspects such as search, information extraction and infor-
mation integration. As envisioned initially by Tim Berners-Lee [4], “the Semantic
Web is an extension of the current Web in which information is given well-deﬁned
meaning, better enabling computers and people to work in cooperation”. Accord-
ing to [7], “the explicit representation of the semantics of data, accompanied with
schema deﬁnitions, will enable a Web that provides a qualitatively new level of
service”. The Semantic Web complements the current Web with machine process-
ability. Thus computers or machines become entities that extract and interpret in-
formation, rather than being just devices to post and render information for human
users.

Figure 6.1 shows the so-called Semantic Web Layer Cake that illustrates the

Semantic Web architecture.

In the lower part of the architecture, we ﬁnd three building blocks that can be used
to encode text (Unicode), to identify resources on the Web (URIs) and to structure
and exchange information (XML). Unicode10 is the ISO standard that deﬁnes the
international character set. It is an extension of the American Standard Code for
Information Interchange (ASCII) that is limited to only 128 characters (a–z, A–Z,
0–9, punctuation) and possesses a larger set of characters including all letters and
signs from all human languages. In total, Unicode deﬁnes 100.000 characters having
a clearly deﬁned process for adding new ones. One distinct feature of Unicode is the

10http://en.wikipedia.org/wiki/Unicode.

6.2 Technical Solution

91

potential to deﬁne extension code pages, where each code page is an interpretation
of the text not a property of it. Unicode can be implemented by different character
encodings. UTF-8 is one possible encoding for Unicode, being also the most used
Unicode encoding on the Web.

The Uniform Resource Identiﬁer (URI) is another standard part of the foun-
dational layers of the Semantic Web. URIs are used to identify resources on the
Web. Depending on their purpose, URIs can be classiﬁed in two classes: Uniform
Resource Names (URNs) and Uniform Resource Locators (URLs). A Uniform Re-
source Name (URN) deﬁnes an item identity, while a Uniform Resource Locator
(URL) provides a method for ﬁnding it. The syntax for deﬁning a URI is:

scheme : [//authority][/path][?query][#fragid]

where the schema is used to distinguish between different types of URI (e.g., http,
ftp, etc.), the authority is normally identiﬁed with a server, the path is identiﬁed
with a directory or a ﬁle on the server, the query adds extra parameters, and fragid
identiﬁes a secondary resource.

Also part of the lower level of the architecture, the Extensible Markup Lan-
guage (XML)11 has been developed by the W3C with the intention of providing a
language that can be used to deﬁne user speciﬁc document types. The development
of XML was motivated by a set of deﬁciencies of existing markup language such
as the inﬂexibility of HTML or the complexity of SGML (note that XML itself is
a subset of SGML). XML has quickly become the predominant standard for ex-
changing structured and semistructured data. XML can be seen as a very ﬂexible
approach that allows markup information about the logical structure of a document
to be mixed with the actual content of the document. Structural information in XML
is deﬁned in terms of elements and attributes. An XML element has a name or label
and a content, where the content can be itself another XML element or set of XML
elements. An element name or label together with markup delimiters is called a tag.
An attribute is a name–value pair inside the opening tag of an element, allowing the
inclusion of additional information as part of tags.

To make the structure of XML documents accessible to machines, two other
standards where developed, namely Document Type Deﬁnition (DTD)12 and XML
schema.13 Using DTD or XML Schema one can deﬁne a set of constraints on the
content allowed to occur as part of XML elements or attributes. Compliance with the
XML syntactic rules makes an XML document well-formed. If an XML document
is well-formed and conforms with a DTD or XML schema speciﬁcation, it is called
a valid XML document. Document Type Deﬁnitions (DTD) specify grammars for
XML documents. However, DTDs provide limited support for specifying structure
and also are not XML documents themselves. XML Schema was introduced to over-
come these limitations. Besides using the XML syntax and providing a richer sup-
port for deﬁning XML structure, XML schema has two other advantages, namely

11http://www.w3.org/standards/xml/.
12http://en.wikipedia.org/wiki/Document_Type_Deﬁnition.
13http://www.w3.org/TR/xmlschema-1/.

92

6 Semantic Web

Fig. 6.2 RDF statement

its reusability and extended set of default datatypes. Regarding reusability, XML
Schema can import and extend the terminology provided by other XML Schemas.
In this context, XML Namespaces play a major role. XML Namespaces are used to
qualify unique names in XML documents.

Resource Description Framework (RDF) [13] is a simple, yet powerful data
model and language for describing Web resources. RDF introduces three fundamen-
tal concepts, namely resources, properties and statements. A resource represents the
entity we want to make statements about. A resource may be anything denoted by
a URI. A property in RDF deﬁnes the relationship between subject resources and
object resources. Using RDF, one can make statements about Web resources in the
form of triples (subject, predicate, object). Statements are RDF triples, where the
subject and predicate are resources and the object can be a resource or a literal. An
example of a RDF statement is available in Fig. 6.2. A literal can be either a plain
literal, i.e., any text, or a type literal, where as types the XML Schema datatypes
are recommended. Using the RDF model, triples can be combined in large graph
structures. The nodes of an RDF graph are resources denoted by URIs, bank nodes,
which are nodes without URIs, or literals. From the logic point of view, an RDF
graph can be seen as a collection of facts where each triple represents a ground fact
if the edges are URIs or literals, or existential quantiﬁed binary predicates, where
existential qualiﬁed variables correspond to blank nodes.

Note that RDF properties are only binary predicates that relate subjects to ob-
jects. Information that usually would be expressed using n-ary predicates cannot be
expressed by means of a single RDF statement but rather a set of statements that
correspond to a set of binary predicates. Different interconnected triples lead to a
more complex graphic model. Basically, an RDF document is a directly connected
graph where the nodes are subjects or objects of the triples, the labels are the predi-
cates and the edges are the RDF statements. The RDF graph representation of a set
of RDF statements is useful especially for humans. For machines, other RDF rep-
resentations are more useful especially when machine interoperability is the goal.
Being understandable by machines also implies being interoperable and exchange-
able across distributed and heterogeneous systems and applications. For this pur-
pose, standardized serialization mechanisms are deﬁned, some of them published as
W3C recommendations, for converting the abstract RDF graph into a concrete ex-
change format. The most known serializations are: RDF/XML, Notation 3 (N3),14

14http://en.wikipedia.org/wiki/Notation_3.

6.2 Technical Solution

93

Turtle.15 and N-Triples.16 The RDF/XML serialization is machine-processable and
XML compliant, enabling the easy exchange of information between very differ-
ent types of systems and applications. Notation 3 (N3) was designed with human-
readability in mind, being more compact and readable than the RDF/XML serializa-
tion. N-Triple is a minimal, plain text serialization format for RDF. Finally, Turtle
(Terse RDF Triple Language) is a superset of N-Triples format providing much
richer format.

RDF deﬁnes a set of complex data structures, i.e., containers and collections.
An RDF container is an open set of resources or literals that contain unspeciﬁed
numbers of elements and possibly duplicates. RDF deﬁnes three types of containers:
• rdf:Bag deﬁnes an unordered set of resources or literals.
• rdf:Seq deﬁnes an ordered set of resources or literals.
• rdf:Alt deﬁnes a set of alternatives, i.e., only one value can be selected.

An RDF collection is a closed set of resources or literals. By contrast to RDF
containers, an RDF collection might contain duplicate elements. Additionally, RDF
introduces the notion of a list rdf:List. The property rdf:ﬁrst points to the ﬁrst
member of the list and a property rdf:rest recursively points to sublist containing the
remaining members or to rdf:nil if the end of the list is reached; rdf:nil represents
an empty list. To represent a complex data structure in RDF, bank nodes can be used
to indirectly attach to a resource a consistent set of properties.

As mentioned previously, RDF can be used to create statements about Web re-
sources. Furthermore, using RDF one can deﬁne statements about other RDF state-
ments, a mechanism that is known as reiﬁcation. Statements are regarded as re-
sources identiﬁed using URIs from which other statements can be created. Reiﬁ-
cation statements can be used to deﬁne belief or trust in other statements. It can
be used to deduce a level of conﬁdence or degree of usefulness for each statement.
Reiﬁcation is a powerful mechanism that offers a high ﬂexibility in modeling, but
simultaneously creates problems when layering other languages on top of RDF.
The major cause of this problem is that by using RDF reiﬁcation, one can make
arbitrary statements over statements and there is consequently no restriction of mix-
ing the data and metadata levels. For example, the statement (rdfs:Class rdf:type
rdfs:Class) states that class is an instance of a class, mixing the data and meta-
data levels. In general, the use of RDF reiﬁcation is discouraged as the semantics of
reiﬁcation are unclear and as reiﬁed statements are quite cumbersome.

RDF not only provides a graph model to publish and link data on the Web, it also
provides the foundational shared data model on which other capabilities are built:
querying (SPARQL17 is built on top of RDF), embedding (RDFa,18 GRDDL19 rely
on the RDF model), and reasoning (RDFS and OWL are deﬁned on top of RDF).

15http://en.wikipedia.org/wiki/Turtle_syntax.
16http://en.wikipedia.org/wiki/N-Triples.
17http://www.w3.org/TR/rdf-sparql-query/.
18http://www.w3.org/TR/xhtml-rdfa-primer/.
19http://www.w3.org/2004/01/rdxh/spec.

94

6 Semantic Web

RDF schema (RDFS) [5] extends RDF by introducing means to model
classes, properties, hierarchy of classes and properties, and simple domain and
range restrictions. RDFS provides the following language constructs: rdfs:Class,
rdfs:subClassOf, rdfs:subPropertyOf, rdfs:domain, and rdfs:range. It
is a
lightweight ontology language that can be used to create taxonomy like ontolo-
gies. The notion of the resource is introduced in RDFS using the rdfs:Resource
construct. All resources are implicit instances of rdfs:Resource. RDFS also intro-
duces the notion of class (rdfs:Class) that can be used to type resources. A class
describes a set of resources, classes being resources themselves. To deﬁne relations
between resources, RDFS provides the language constructs needed to deﬁne proper-
ties, i.e., rdfs:domain to specify the classes associated with a property, rdfs:range
to specify the type of the property value, and subPropertyOf to deﬁne hierarchies
of properties. The semantics of RDFS is based on sets and set operators (union inter-
section and inclusion). RDF already provides the membership declaration property
rdf:type that allows one to capture in a graph structure which resource belongs
to which class (a kind of set) and which couples of resources belong to which
relation (another kind of set). RDFS provides the vocabulary to describe the re-
lations between these sets; relations between classes, relations between properties
and between classes and properties. Mixing the data and metadata levels is inher-
ited by RDFS from RDF. There is no restriction on changing the semantics of the
ontology modeling constructs, which makes layering of logical languages such as
OWL on top of RDF/RDFS a difﬁcult task. Another issue that hampers the proper
layering and furthermore the integration of Semantic Web languages is the differ-
ent assumptions these languages adhere to, i.e., closed world assumption or open
world assumption. In a closed world, any missing information is considered as false,
while in an open world missing information is treated as unknown. Furthermore, in
languages or systems that adhere to the closed world assumption, the schema in-
formation behaves as constraints over the data. While RDF adheres to open world
assumption, RDFS is agnostic in this respect, leaving at the application level the
decision under which assumption the information should be interpreted. The RDFS
approach on open vs. closed world assumption is more appropriate, allowing dif-
ferent logical languages to be more easily layered on top of RDFS than on top of
RDF.

The SPARQL Protocol and RDF Query Language (SPARQL) [19] is the de-
facto standard used to query RDF data. While RDF and the RDF Schema provide a
model for representing Semantic Web data and for structuring semantic data using
simple hierarchies of classes and properties, respectively, the SPARQL language
and protocol provide the means to express queries and retrieve information from
across diverse Semantic Web data sources. The natural question is why we need a
new query language, given that XML query languages can be used to query over
the XML serialization of an RDF graph. The need for a new language is motivated
by the different data models and semantics at the level of XML and RDF, respec-
tively. More precisely, the existing XML query languages, such as XPath20 and

20http://www.w3.org/TR/xpath/.

6.2 Technical Solution
(cid:2)
PREFIX ex: <http://example.org/> .
SELECT ?name
WHERE
{
ex:john, ex:hasName, ?name .
}(cid:4)

Listing 6.1 Simple SPARQL query

95

(cid:3)

(cid:5)

XQuery,21 can be used to formulate queries dependent on the XML data structure
that is queried. For example, the information encoded in the RDF triple (ex:john,
ex:hasName, “John Smith”) can be syntactically represented in XML in multi-
ple ways, and there consequently exist multiple query representations to search for
John’s name, depending on the XML structure used to encode the information. By
using RDF, we abstract from the multitude of syntactic representations in XML, and
focus on the data and its meaning. The SPARQL query language was developed for
the RDF layer of the Semantic Web architecture (see Fig. 6.1). The query language
has been developed without considering the other core languages of the Semantic
Web, namely RDFS, OWL and RIF.

The SPARQL is a matching graph pattern language. It deﬁnes a set of graph
patterns, the simplest being the triple pattern. A triple pattern is like a normal RDF
triple but with the possibility of a variable instead of an RDF term in the subject,
predicate, or object positions. An example of a simple SPARQL query is provided
in Listing 6.1.

SPARQL introduces the notion of variable binding, that is, a pair (variable,
RDF term), where variable is a query variable of interest indicated by ? or $ and the
RDF term is the value assigned to the variable after the query has been executed.
Similar to the namespace mechanism used for writing RDF/XML, SPARQL allows
the deﬁnition of preﬁxes for namespaces. Preﬁxes are used inside a query to increase
its readability. SPARQL introduced a set of constructs and clauses that could be part
of a query. The SELECT clause identiﬁes the variables to appear in the query results
and the WHERE clause provides the basic graph pattern to match against the data
graph. Additional constructs are FROM that is used to refer to the name of the graph
to be queried, LIMIT to put an upper bound on the number of solutions returned,
DISTINCT to eliminate duplicate solutions, REDUCED to permit but not to enforce
duplicate solutions to be eliminated, OFFSET to specify that the solutions generated
should start after the speciﬁed number of solutions, ORDER BY to establish the
order of a solution sequence, etc.

More complex graph patterns can be formed by combining smaller patterns in
various ways. SPARQL introduces four complex graph patterns, namely Group
Graph Patterns, Optional Graph Patterns, Alternative Graph Patterns, and Patterns
on Named Graphs. A Group Graph Pattern is a set of graph patters that must all
match. An Optional Graph Pattern deﬁnes additional patterns that may extend the
solution. An Alternative Graph Pattern consists of two or more possible patterns

21http://www.w3.org/TR/xquery/.

96

6 Semantic Web

that are tried when executing the query. Finally, in the case of Patterns on Named
Graphs, patterns are matched against named graphs.

Graph patterns as part of SPARQL queries. SPARQL has four query forms.
These query forms use the solutions from pattern matching to form result sets or
RDF graphs. The four query forms supported by SPARQL are the classical SE-
LECT query which returns all, or a subset of, the variables bound in a query pattern
match, CONSTRUCT which returns an RDF graph constructed by substituting vari-
ables in a set of triple templates, ASK which returns a boolean indicating whether
a query pattern matches or not, and DESCRIBE which returns an RDF graph that
describes the resources found.

The SPARQL language 1.0 discussed in this chapter does not provide support
for aggregate functions such as counting, numerical min/max/average. It also lacks
support for expressing subqueries, i.e., queries inside queries, negation as failure
like in relation databases, project expressions, etc. The SPARQL Working Group
is working towards deﬁning a new version of SPARQL, i.e., SPARQL 1.122 that
addresses the above mentioned limitations of SPARQL 1.0.

The backbone of the Semantic Web are ontologies [6]. An ontology, as deﬁned
in [9], is a “formal, explicit speciﬁcation of a shared conceptualization”. The “speci-
ﬁcation” part of the previous deﬁnition indicates that an ontology is a concrete form
of representing a conceptualization of a domain. An ontology is “formal” because
it can be processed by machines represented using a formal language. Furthermore,
an ontology is “explicit” because the knowledge encoded is explicitly speciﬁed.
Finally, the “share” part of the deﬁnition previously quoted refers to an agreed con-
sensus among the parties involved in the creation of the ontology. In a nutshell, an
ontology is deﬁned in terms of concepts, properties or relations, axioms, and in-
dividuals. Concepts are the core elements of the conceptualization corresponding to
entities of the domain being described. Properties and relations are used to describe
interconnections between concepts. Individuals are instantiations of the ontological
concepts.

A set of formalisms and languages inspired by the work done in Knowledge
Representation (e.g., Description Logics [1], Logic Programming [12, 14]) were
created to formalize knowledge on the Semantic Web. Two of these formalisms,
namely RDF(S) and OWL, were standardized by the W3C consortium.

OWL,23 which stands for Web Ontology Language, is actually the standard
language for representing knowledge on the Web. This language was designed to
be used by applications that need to process the content of information on the Web
instead of just presenting information to human users [16]. Using OWL one can
explicitly represent the meaning of terms in vocabularies and the relationships be-
tween those terms. In the Semantic Web stack architecture introduced in Fig. 6.1,
OWL is part of the ontology language layer and is placed above the RDF and XML
layers. Using OWL, one can express much richer relationships than with RDF(S),
thus yielding the beneﬁt of enhanced inference capabilities.

22http://www.w3.org/TR/sparql11-query/.
23http://www.w3.org/2004/OWL/.

6.2 Technical Solution

97

OWL is based on Description Logics and has its origin in DAML+OIL ontol-
ogy language [10], incorporating lessons learned from the design and application of
DAML+OIL which is a combination of OIL [8] and DAML-ONTO [15] ontology
languages.

When designing a language, there is always a trade-off between expressivity of
the language and tractability of inference that can be done using that language. With
OWL, this trade-off has been partly addressed through a layered approach. There
are three OWL sub-languages: OWL Lite, OWL DL and OWL Full. Starting from
the lower layer, OWL Lite, up to the upper layer, OWL Full, each sub-language is
enriched in syntax and semantic.

OWL Full is layered syntactically and semantically on top of RDF(S) provid-
ing maximum expressivity, but with no guarantee of computational behavior. OWL
DL restricts OWL Full to the part which offers completeness (a guarantee that an
answer can and will be found) and decidability (a guarantee that the computation
will end in a ﬁnite time). OWL Lite restrict OWL DL further to a language that can
be used to express classiﬁcation hierarchy and simple constraints. OWL Lite can
be seen as a variant of the SHIF (D) description logic language, whereas OWL
DL is a variant of the SHOIN (D) language [11]. The SHIF (D) language allows
complex class descriptions, including conjunction, disjunction, negation, existential
and universal value restrictions for roles, role hierarchies, transitive roles, inverse
roles, a restricted form of cardinality restrictions (cardinality 0 or 1) and (limited)
support for concrete domains. SHOIN (D) adds support for individuals in class
descriptions and arbitrary cardinality constraints.

There are two major syntaxes for OWL. The most prominent one is based on
RDF/XML syntax [2]. The second syntax, called abstract syntax [18] was developed
for OWL DL and is similar to the syntax used in many Description Logics reasoners.
The abstract syntax can only be used for the DL dialect of OWL. The RDF/XML
syntax is more complex than the abstract syntax and not as intuitive to use.

The semantic of OWL assigns meaning to all variants of OWL. OWL has a direct
model-theoretic semantics24 which is based on DAML+OIL model-theoretic se-
mantics. There are two ways of describing the semantic: as an extension of RDF(S)
model theory and as a direct model-theoretic semantics of OWL.

OWL2 [17] is the result of the latest development of the Web Ontology Lan-
guage. A number of shortcomings were identiﬁed with respect to OWL 1, especially
with the OWL Lite variant. OWL Lite has been deﬁned as a much too expressive De-
scription Logic. This hampered implementation of Lite reasoning based on existing
semantic repository technology and also made layering rules on top of this language
unfeasible. OWL 2 deﬁnes actually three new sublanguages: OWL2EL, OWL2QL
and OWL2RL proﬁles. OWL2EL is particularly suitable for applications employing
ontologies that deﬁne very large numbers of classes and/or properties. It provides
polynomial time algorithms for all the standard reasoning tasks of description logic.
OWL2QL enables efﬁcient query answering over large instance populations, and
OWL2RL restricts the expressiveness towards rule languages. This is currently the

24http://www.w3.org/TR/owl-semantics/.

98

6 Semantic Web

pathway that most industrial semantic repository developers follow and together
with OWL2QL will probably deﬁne the most important Semantic Web representa-
tion languages from a technological point of view. The OWL2QL proﬁle is designed
so that sound and complete query answering is in LOGSPACE with respect to the
size of the data (assertions), while providing many of the main features necessary
to express conceptual models such as UML class diagrams and ER diagrams. It is
designed so that data (assertions) stored in a standard relational database system can
be queried through an ontology via a simple rewriting mechanism, i.e., by rewriting
the query into an SQL query that is then answered by the RDBMS system, without
any changes to the data.

The Rule Interchange Format (RIF)25 is the W3C Recommendation that de-
ﬁnes a framework to exchange rule-based languages on the Web. Like OWL, RIF
deﬁnes a set of languages covering various aspects of the rule layer of the Semantic
Web. More precisely RIF includes three dialects, a Core dialect which is extended
into a Basic Logic Dialect (BLD) and Production Rule Dialect (PRD). RIF-BLD
deﬁne a simple logic-oriented rule language, RIF-PRD captures most of the aspects
of the production rule systems, and RIF-Core is the intersection between these lan-
guages. Essentially, RIF covers rule languages with different semantics, i.e., logic
based rule languages with a declarative interpretation, and production based rule
languages. The former usually have a declarative semantics in terms of a variation
of a minimal Herbrand model and are an alternative model for databases called de-
ductive databases. The latter usually only have an operation semantics and are used
to express dynamic aspects of processes. They are much closer to being a kind of
programming language based on a blackboard architecture and event triggers. Fi-
nally, these three dialects are complemented by The Framework for Logic Dialects
(RIF-FLD) as a means to deﬁne new RIF dialects.

6.3 Extensions

Linked Data is a relatively new initiative that can be seen as a sub-topic and an
extension of Semantic Web. It is used to “describe a method of exposing, sharing,
and connecting data via dereferenceable URIs on the Web”.26 The vision of Linked
Data is primarily to publish structured data in RDF format. The focus is shifted from
the ontological level and inference which are central for the classic Semantic Web,
to provide simple principles and methods of publishing and linking data on the Web.
Introduced in [3] by the inventor of the Web, Sir Tim Berners-Lee, Linked Data
is deﬁned as RDF graphs, published so that they can be navigated across servers
by following the links that interconnect these graphs. There are four simple design
principles that need to be followed when publishing data as part of Linked Data:
• Using URIs as names for things.

25http://www.w3.org/2005/rules/wiki/RIF_Working_Group.
26http://en.wikipedia.org/wiki/Linked_Data.

6.3 Extensions

99

• Using HTTP URIs so that people can look up those names.
• When someone looks up a URI, providing useful RDF information.
• Including RDF statements that link to other URIs so that they can discover related

things one should follow.

Implementation of these principles has the potential to change the Web of doc-
uments as we know it today, into a Web of data. The Web of Data is envisioned as
a global database consisting of objects and their descriptions in which objects are
linked with each other with a high degree of object structure, with explicit semantics
for links and content designed for humans and machines.

One community project that is realizing the idea of Linked Data and the Web of
Data is the Linked Open Data Project.27 Its goal is to extend the Web with a data
commons by publishing various open data sets as RDF on the Web and by setting
RDF links between data items from different data sources. Since the beginning of
2007, Linking Open Data project (LOD) has been growing continuously. In October
2007, datasets consisted of over two billion RDF triples, which were interlinked by
over two million RDF links. By May 2009, this had grown to 4.2 billion RDF triples,
interlinked by around 142 million RDF links. Currently the LOD cloud contains 203
data sets, 25 billion RDF triples and more than 400 million RDF links. Figure 6.3
depicts the Linking Open Data cloud as available in September 2010.

The central dataset of the LOD is DBPedia,28 an effort to extract structured in-
formation from Wikipedia and make this information available on the Web as RDF.
DBPedia is referred to within multiple datasets of the LOD cloud providing a high
level of connectivity. Other linked LOD datasets are: Wordnet, the RDF represen-
tation of the most popular lexical knowledge base, Geonames29 a worldwide geo-
graphical database, UniProt30 the largest integrated database with protein and gene-
related information, OpenCyc31 the most popular upper-level and general ontology
and many mores.

As mentioned earlier regarding the publishing of data as part of LOD, four princi-
ples should be followed. A simple algorithm compliant with these principles would
include the following simple steps:

• Select the relevant vocabularies and reuse existing vocabularies to increase the

value of the data set and to increase interoperability.

• Partition the RDF data graph into data pages.
• Assign a URI to each data page.
• Create HTML variants for each data page to allow rendering of pages in browsers.
• Assign a URI to each entity (cf. “Cool URIs for the Semantic Web”).
• Add page metadata such as publisher, license, topics, etc., and link sugar.

27http://esw.w3.org/topic/SweoIG/TaskForces/CommunityProjects/LinkingOpenData.
28http://dbpedia.org/.
29www.geonames.org/.
30www.uniprot.org/.
31http://www.opencyc.org/.

100

6 Semantic Web

/
d
o
l
/
0
1
/
7
0
0
2
/
e
d
.
k
a
i
n
a
g
y
c
.
d
r
a
h
c
i
r
/
/
:
p
t
t
h
m
o
r
f

e
r
u
g
i
F

.
0
1
0
2
r
e
b
m
e
t
p
e
S

,

d
u
o
l
c

a
t
a
D
n
e
p
O
g
n
i
k
n
i
L

3
.
6
e
r
u
g
i
F

6.4 Summary

101

• Add a Semantic Sitemap to allow crawlers to ﬁnd the data set or SPARQL end

points to access the data set.

To support the development of LOD, various vocabularies and tools have been
developed. voiD,32 the “Vocabulary of Interlinked Datasets” is just such an approach
that provides the terminology needed to describe LOD datasets. Using voiD one
can specify what a dataset is about (topic, technical details), how and under what
conditions it can be accessed, how the dataset is interlinked with other datasets,
qualitative aspects of the dataset such as interlinking with other dataset as well as
quantitative statistics such as the number of links, resources, etc. Other approaches
and tools exist for bringing legacy data to the Web of Data and to make use of LOD
data, i.e., to search, browse and mashup Linked Data.

To conclude, the Web of Data is a promising approach that extends the classical
Semantic Web by transforming the Web from a Web of documents into a Web of
data. The focus is on publishing data as RDF and on making links between datasets.
A promising and interesting future direction to explore with respect to Linked Data
is providing a service layer abstraction on top of the LOD layer.

6.4 Summary

This chapter provided a short overview of a challenging and continuously grow-
ing research area, called the Semantic Web, which aims to develop methods and
technologies that enable processing, querying and integrating information on the
Web in a transparent and automatic fashion. First, the success factors of the current
Web as well as its limitations were discussed. In particular, ﬁnding, extracting and
combining information are major limitations of the current Web. The solution pro-
posed by the Semantic Web is to provide formal descriptions or machine-readable
metadata that would enable automated agents and other software to access the Web
more intelligently. First, the so-called Semantic Web Layer Cake that illustrates the
Semantic Web architecture was introduced. The components and languages of the
architecture introducing the basic concepts and aspects of each of language were dis-
cussed in more details. The foundation layer of the Semantic Web, which includes
technologies and languages fundamental to Web itself, was introduced. Unicode,
the Uniform Resource Identiﬁer (URI), the Extensible Markup Language (XML),
the Document Type Deﬁnition (DTD) and the XML Schema are also part of this
large layer. The languages that are part of the core of Semantic Web were pre-
sented in details, including the Resource Description Framework (RDF) and RDF
Schema (RDFS) as data model and simple ontology language, SPARQL as the stan-
dard query language for RDF data, the Web Ontology Language (OWL) version 1
and 2 and the Rule Interchange Format (RIF). The chapter concludes with a discus-
sion on extensions of the current and the Semantic Web towards a larger, more open
and interconnected Web of data, known as Linked Open Data.

32http://semanticweb.org/wiki/VoiD.

102
(cid:2)
<rdf:RDF

xmlns:j.0="http://xmlns.com/foaf/0.1/"
xmlns:j.1="http://www.deri.org/person#"
xmlns:rdf="http://www.w3.org/1999/02/22−rdf−syntax−ns#" >

<rdf:Description rdf:about="http://www.dieter.fensel">

<j.0:depiction>http://www.deri.at/images/members/dieter_fensel.jpg</j.0:depiction>
<j.1:workStreetAddress>Technikerstrasse 21a</j.1:workStreetAddress>
<j.0:givenname></j.0:givenname>
<j.0:mbox>dieter.fensel@sti2.at</j.0:mbox>
<j.0:homepage>http://www.fensel.com</j.0:homepage>
<j.1:middle_name></j.1:middle_name>
<j.1:workOrganization>University of Innsbruck</j.1:workOrganization>
<j.1:workDepartment>Institute of Computer Science</j.1:workDepartment>
<j.1:workPostalCode>A6020</j.1:workPostalCode>
<j.1:workFaxNumber>+43 512 507 9872</j.1:workFaxNumber>
<j.1:workCity>Innsbruck</j.1:workCity>
<j.0:name>Univ. Prof. Dr. Dieter Fensel</j.0:name>
<j.1:workPhoneNumber>+43 512 507 6485, 6488</j.1:workPhoneNumber>
<j.1:workCountry>Austria</j.1:workCountry>
<j.0:title></j.0:title>
<j.0:family_name>Fensel</j.0:family_name>

</rdf:Description>

</rdf:RDF>
(cid:4)

Listing 6.2 RDF annotation representing a person

6.5 Exercises

6 Semantic Web

(cid:3)

(cid:5)

Exercise 1 Please, answer these questions to the best of your knowledge.

1. What novelty and advantages does the Semantic Web bring as compared to Web

1.0 and Web 2.0?

2. What are the conceptual differences between the data model of XML and the
data model of RDF? Compare the features and application areas of supporting
APIs for XML and RDF.

3. Compare query languages XPATH and SRARQL. What are the main concepts
and similarities, what are the main differences? Can you recognize relations to
Relational Database Query languages such as SQL?

4. What does OWL add on top of RDF/RDFS? In what sense is OWL DL more

restrictive than RDFS?

Exercise 2 Find an OWL ontology, for instance, using Swoogle Semantic Web
search engine (http://swoogle.umbc.edu.), and explain at least ﬁve different concepts
and properties in the ontology by using the relations and axioms you can ﬁnd in the
ontology itself. Pick an ontology which uses some constructs not expressible in
RDFS.

Exercise 3 Clarify in which ways the following RDF annotation representing a
Person (Listing 6.2) does not comply with the FOAF schema. What are the changes
that need to be done to make this annotation compliant with the FOAF speciﬁcation?

Exercise 4 Answer the questions about SPARQL queries.
• Given the following data and SPARQL query, what result will the query deliver?

References

Data:

(cid:2)
@preﬁx foaf: <http://xmlns.com/foaf/0.1/> .
_:a foaf:name "Anna" ;
foaf:mbox <mailto:anna@example.net> .
_:b foaf:name "Ioan" .
(cid:4)

Query:

(cid:2)
PREFIX foaf: <http://xmlns.com/foaf/0.1/>
SELECT ?name WHERE {
?node foaf:name ?name .
?node foaf:mbox ?mbox .
}(cid:4)

103

(cid:3)

(cid:5)

(cid:3)

(cid:5)

• Given the following data and SPARQL query, what result will the query deliver?

Data:

(cid:2)
@preﬁx dc10: <http://purl.org/dc/elements/1.0/> .
@preﬁx dc11: <http://purl.org/dc/elements/1.1/> .
_:a dc10:title "SPARQL Query Language Tutorial" .
_:b dc11:title "SPARQL Query Language (2nd ed)" .
_:c dc10:title "SPARQL" .
_:c dc11:title "SPARQL" .
(cid:4)

Query:

(cid:2)
PREFIX dc10: <http://purl.org/dc/elements/1.0/>
PREFIX dc11: <http://purl.org/dc/elements/1.1/>
SELECT DISTINCT ?title
WHERE { { ?book dc10:title ?title } UNION
{ ?book dc11:title ?title } }
(cid:4)

• What does the following SPARQL query perform?
(cid:2)
CONSTRUCT { ?friend pim:fullName ?name .
?friend foaf:mbox ?mbox }
WHERE { ?person foaf:knows ?friend .
?friend foaf:given ?name .
?friend foaf:mbox ?mbox .
FILTER regex(?person, ‘‘Anna’’) .}
(cid:4)

(cid:3)

(cid:5)

(cid:3)

(cid:5)

(cid:3)

(cid:5)

References

1. Baader, F., Calvanese, D., McGuinness, D.L., Nardi, D., Patel-Schneider, P.F. (eds.): The De-

scription Logic Handbook. Cambridge University Press, Cambridge (2003)

2. Beckett, D.: RDF/XML syntax speciﬁcation (revised). Recommendation 10 February 2004,

W3C (2003)

3. Berners-Lee, T.: Design issues: linked data. Technical rep. (2006). Available at http://www.

w3.org/DesignIssues/LinkedData.html

104

6 Semantic Web

4. Berners-Lee. T., Hendler, J., Lassila, O.: The Semantic Web. Scientiﬁc American 284(5),

34–43 (2001)

5. Brickley, D., Guha, R.V.: RDF vocabulary description language 1.0: RDF schema. W3C Rec-

ommendation. Technical rep. (2004). Available at http://www.w3.org/TR/rdf-schema/

6. Fensel, D.: Ontologies: Silver Bullet for Knowledge Management and Electronic Commerce.

Springer, Berlin (2003)

7. Fensel, D., Musen, M.A.: The Semantic Web: A brain for humankind. IEEE Intelligent Sys-

tems 16(2), 24–25 (2001)

8. Fensel, D., van Harmelen, F., Horrocks, I., McGuinness, D.L., Patel-Schneider, P.F.: OIL: An

ontology infrastructure for the semantic web. IEEE Intelligent Systems 16(2) (2001)

9. Gruber, T.R.: A translation approach to portable ontology speciﬁcations. Knowledge Acquisi-

tion 5(2), 199–220 (1993)

10. Horrocks, I., van Harmelen, F.: Reference description of the DAML+OIL (March 2001)
ontology markup language. Technical report, DAML (2001). http://www.daml.org/2001/03/
reference.html

11. Horrocks, I., Patel-Schneider, P.F.: Reducing OWL entailment to description logic satisﬁa-
bility. In: Proc. of the 2003 International Semantic Web Conference (ISWC 2003), Sani-
bel Island, Florida (2003). http://www.cs.man.ac.uk/~horrocks/Publications/download/2003/
HoPa03b.pdf

12. Kifer, M., Lausen, G., Wu, J.: Logical foundations of object-oriented and frame-based lan-

guages. Journal of the ACM 42(4), 741–843 (1995)

13. Klyne, G., Carroll, J.J.: Resource description framework (RDF): concepts and abstract
syntax. W3C Recommendation. Technical rep. (2004). Available at http://www.w3.org/TR/
rdf-concepts/

14. Lloyd, J.W.: Foundations of Logic Programming, 2nd edn. Springer, Berlin (1987)
15. McGuinness, D.L.: Ontologies come of age. In: Fensel, D., Hendler, J., Lieberman, H.,
Wahlster, W. (eds.) Spinning the Semantic Web: Bringing the World Wide Web to Its Full
Potential, pp. 171–194. MIT Press, Cambridge (2003). Chap. 6

16. McGuinness, D.L., van Harmelen, F.: Owl web ontology language overview (February 2004).

Technical report, W3C (2004). http://www.w3.org/TR/owl-features/

17. Motik, B., Grau, B.C., Horrocks, I., Wu, Z., Fokoue, A., Lutz, C.: OWL 2 web ontology

language proﬁles. Recommendation 27 October 2009, W3C (2009)

18. Patel-Schneider, P.F., Hayes, P., Horrocks, I.: OWL web ontology language semantics and

abstract syntax. Recommendation 10 February 2004, W3C (2004)

19. Prud’hommeaux, E., Seaborne, A.: SPARQL query language for RDF. W3C Recommenda-

tion. Technical rep. (2008). Available at http://www.w3.org/TR/rdf-sparql-query/

Part II
Web Service Modeling Ontology Approach

Chapter 7
Web Service Modeling Ontology

Abstract This chapter presents the Web Service Modeling Ontology, an ontology
for describing various aspects related to Semantic Web Services. WSMO is the ma-
jor initiative in the area of Semantic Web Services in Europe. The starting point of
WSMO was the Web Service Modeling Framework (WSMF) (Fensel and Bussler in
Electronic Commerce Research and Applications 1(2):113–137, 2002), which was
reﬁned and extended, resulting in (i) a formal ontology, the Web Service Modeling
Ontology (WSMO), (ii) a formal family of languages, the Web Service Modeling
Language (WSML), and (iii) an execution environment, the Web Service Modeling
Environment (WSMX). The four main elements of WSMF have been adopted and
reﬁned in WSMO, resulting in four main elements for describing Semantic Web Ser-
vices: (i) ontologies that provide the terminology used by other elements, (ii) goals
that deﬁne the problems that should be solved by Web services, (iii) Web services
descriptions that deﬁne various aspects of a Web service, and (iv) mediators which
facilitate the resolution of interoperability problems. WSMO is a key technology
needed for the successful realization of Semantic Web Services and Semantically
Enabled Service-oriented Architectures. It provides a conceptual model for Seman-
tic Web Services that combines the design principles of the Web, the Semantic Web
and distributed service oriented computing in order to provide a clean modeling
solution for various aspects related to Semantic Web Services.

7.1 Motivation

Current Web service technologies around SOAP [11], WSDL [3], and UDDI [1]
operate at the syntactic level. Therefore, although they support interoperability be-
tween the many diverse application development platforms that exist today through
common standards, they still require human interaction to a large extent: the human
programmer has to manually search for appropriate Web services in order to com-
bine them in a useful manner. Having a human programmer in the loop that needs
to take care of various service related tasks limits the scalability of service-oriented
solutions and greatly curtails the added economic value of envisioned with the ad-
vent of Web services [4]. In order to automate tasks such as Web service discovery,
composition and execution, semantic descriptions of Web services are required. Se-
mantic Web Services are building on top of Web services technology by describing

D. Fensel et al., Semantic Web Services,
DOI 10.1007/978-3-642-19193-0_7, © Springer-Verlag Berlin Heidelberg 2011

107

108

7 Web Service Modeling Ontology

various aspects of services using explicit, machine-understandable semantics that
enables a certain degree of automation for various service related tasks. In a nut-
shell, work in the area of Semantic Web [2] is being applied to Web services in
order to keep the intervention of the human user to a minimum. WSMO provides a
fully-ﬂedged framework for Semantic Web Services. It includes a conceptual model,
a formal language with a formal syntax and semantics based on different logics in
order to support different levels of logical expressiveness, and an execution envi-
ronment that is able to discover, select, compose and invoke Semantic Web Services
modeled and formalized in WSMO. This chapter introduces one of the most im-
portant approaches to Semantic Web Services, namely the Web Service Modeling
Ontology.

7.2 Technical Solution

The WSMO approach to Semantic Web Services includes: (i) the Web Service Mod-
eling Ontology (WSMO), a conceptual model for Semantic Web Services, (ii) the
Web Service Modeling Language (WSML), a language providing a formal syn-
tax and semantics for WSMO, and (iii) the Web Service Execution Environment
(WSMX), an execution environment for WSMO descriptions formalized in WSML.
The rest of this section describes in detail the WSMO conceptual model. The other
two building blocks of the WSMO approach, namely the Web Service Modeling
Language (WSML) and the Web Service Execution Environment (WSMX), will be
described in Chaps. 8 and 9, respectively.

WSMO [7] provides ontological speciﬁcations for the core elements of Semantic

Web Services being based on the following design principles:

• Web Compliance

WSMO inherits the concept of Uniform Resource Identiﬁer (URI) for unique
identiﬁcation of resources as the essential design principle for the Word Wide
Web. Moreover, it adopts the concept of namespaces for denoting consistent in-
formation spaces, supports XML and other W3C Web technology recommenda-
tions, as well as the decentralization of resources.

• Ontology Based

Ontologies are used as the data model throughout WSMO, meaning that all re-
source descriptions as well as all data interchanged during service usage are based
on ontologies. WSMO also supports the ontology languages deﬁned for the Se-
mantic Web.

• Strict Decoupling

Decoupling denotes that WSMO resources are deﬁned in isolation, meaning that
each resource is speciﬁed independently without regarding possible usage or in-
teractions with other resources. This complies with the open and distributed na-
ture of the Web.

7.2 Technical Solution

• Centrality of Mediation

109

As a complementary design principle to strict decoupling, mediation addresses
the handling of heterogeneities that naturally arise in open environments. Hetero-
geneities can occur in terms of data, underlying ontology, protocol, and process.
WSMO recognizes the importance of mediation for the successful deployment of
Web services by making mediation a ﬁrst class component of the framework.

• Ontological Role Separation

Users, or more generally clients, operate in speciﬁc contexts which will not be
the same as for available Web services. For example, a user may wish to book a
holiday according to preferences for weather, culture, and childcare, whereas Web
services will typically cover airline travel and hotel availability. The underlying
epistemology of WSMO differentiates between the desires of users or clients and
available services.

• Description versus Implementation

WSMO distinguishes between the descriptions of Semantic Web Services ele-
ments (description) and executable technologies (implementation). The former
requires a concise and sound description framework based on appropriate for-
malisms in order to provide concise semantic descriptions. The latter is concerned
with the support of existing and emerging execution technologies for the Seman-
tic Web and Web services.

• Execution Semantics

In order to verify the WSMO speciﬁcation, the formal execution semantics of
reference implementations such as WSMX as well as other WSMO-enabled plat-
forms provide the technical realization of WSMO. This principle serves as a
means to precisely deﬁne the functionality and behavior of the systems that are
WSMO-compliant.

• Service versus Web service

A Web service is a computational entity that is able to achieve a user goal by
invocation. A service, in contrast, is the actual value provided by this invoca-
tion. WSMO provides the means to describe Web services that provide access
(searching, buying, etc.) to services. WSMO is designed as a means to describe
the former, and not to replace the functionality of the latter.

Based on these design principles, the WSMO meta-model has four top level el-
ements which can be seen in Fig. 7.1, namely Ontologies, Web Services, Goals,
and Mediators. To effectively describe Semantic Web Services, we need to under-
stand each of these four elements. WSMO makes use of the Meta-Object Facility
(MOF) [6] speciﬁcation to deﬁne its meta-model. The MOF provides a language
and framework for specifying technology neutral meta-models. The beneﬁt of using
MOF is that the model and the languages that are ultimately used to describe Seman-
tic Web Services are separated from one another. This separation gives signiﬁcantly
more freedom than with competing approaches such as OWL-S (see Chap. 11). In
WSMO, every element can be annotated using the WSMO annotations. One of the
most used standards for annotations is the Dublin Core (DC) Metadata Set [12]. In
the following sections, we use the MOF speciﬁcation to describe the four top level
elements of the WSMO metamodel and their child elements.

110

7 Web Service Modeling Ontology

Fig. 7.1 WSMO top level
elements

(cid:2)
Class ontology

hasAnnotations type annotations
importsOntology type ontology
usesMediator type ooMediator
hasConcept type concept
hasRelation type relation
hasFunction type function
hasInstance type instance
hasRelationInstance type relationInstance
hasAxiom type axiom

(cid:4)

Listing 7.1 Ontology deﬁnition

7.2.1 Ontologies

(cid:3)

(cid:5)

Ontologies in WSMO provide the terminology used across the descriptions of all
other WSMO elements. Ontologies are crucial to the success of Semantic Web Ser-
vices, as they provide the means by which enhanced information processing be-
comes possible and complex interoperability problems can be solved. WSMO is an
epistemological model in that it is general enough to intuitively capture existing lan-
guages used for describing ontologies. In Listing 7.1 a WSMO ontology is described
using the MOF notation.

7.2.1.1 Annotations

It is possible to add annotations onto all WSMO elements. They include aspects
such as the creator, the creation date, the version, etc. The elements deﬁned by
the Dublin Core Metadata Initiative [12] are taken as a starting point. Dublin Core
is a set of attributes that deﬁne a standard for cross-domain information resource
description. WSMO uses IRIs for identiﬁcation of elements. This is also true of an-
notations which are speciﬁed as key value pairs, where the key is an IRI identifying
the property, and the value is another element.

7.2.1.2 Imported Ontologies

All top levels elements within the WSMO meta-model may use the importsOn-
tology statement to import ontologies that contain the relevant concepts needed to

7.2 Technical Solution
(cid:2)
Class concept

hasAnnotations type annotations
hasSuperConcept type concept
hasAttribute type attribute
hasDeﬁnition type logicalExpression multiplicity = single−valued

Class attribute

hasAnnotations type annotations
hasRange type concept multiplicity = single−valued

(cid:4)

Listing 7.2 Concept deﬁnition

111

(cid:3)

(cid:5)

build a description, for example, a WSMO Web service description will import those
WSMO Ontologies that contain concepts needed to describe the service in question.

7.2.1.3 Mediators for Importing Ontologies

Of course, it may not always be possible to directly import a given ontology, as
mismatches between statements in the importing and imported ontology or between
any two given imported ontologies may exist. In this case, a mediator is required,
and the ontology is imported via this mediator. This mediator deals with the align-
ment, merging and transformation of the imported ontology so that existing hetero-
geneity issues that may arise are ﬁxed. Like the importsOntology statement, the
usesMediator statement may be used on all top level elements within the WSMO
meta-model.

7.2.1.4 Concepts

Concepts represent the basic agreed upon terminology for a given domain. A con-
cept is made up of a set of attributes, where each attribute has a name and a type.
Using the MOF notation, the deﬁnition of a concept is depicted in Listing 7.2.

A concept can also be a sub-concept of one or more direct super-concepts us-
ing the hasSuperConcept statement. Sub-concepts inherit the signatures of all its
super-concepts, for example, all attributes deﬁned for a given concept will also hold
for any of its sub-concepts.

Using the hasAttribute statement a set of attributes on the concept can be speci-
ﬁed. The MOF deﬁnition of an attribute is also speciﬁed in Listing 7.2. The range of
an attribute can be constrained to a given concept, meaning that all instances of the
concept that specify a value for this attribute must conform to this range restriction.
Furthermore, a concept can be further reﬁned by adding a logical expression
through the hasDeﬁnition statement. This logical expression can be used to express
additional constraints on the concept than cannot be captured through the hasAt-
tribute or hasSuperConcept statement.

112
(cid:2)
Class relation

hasAnnotations type annotations
hasSuperRelation type relation
hasParameter type parameter
hasDeﬁnition type logicalExpression multiplicity = single−valued

Class parameter

hasAnnotations type annotations
hasDomain type concept multiplicity = single−valued

(cid:4)

Listing 7.3 Relation deﬁnition

(cid:2)
Class function sub−Class relation
(cid:4)

hasRange type concept multiplicity = single−valued

Listing 7.4 Function deﬁnition

7.2.1.5 Relations and Functions

7 Web Service Modeling Ontology

(cid:3)

(cid:5)

(cid:3)

(cid:5)

Relations and functions deﬁne connection between several concepts. The arity of a
relation is not restricted, thus a relation is able to model dependencies between two
or more concepts. The MOF deﬁnition of a relation is presented in Listing 7.3.

Each relation can have zero or more super-relations. A relation inherits the sig-
nature of the super relation along with any associated constraints. Similarly to at-
tributes for concepts, a relation can deﬁne a set of parameters, which may be a
named or an ordered unnamed set. It is possible to deﬁne the domain of each of the
parameters, where the domain speciﬁes the allowed values that can be placed in this
slot of the relation when it is instantiated. WSMO Ontologies can also have func-
tions, speciﬁed with the hasFunction statement. Functions, as described in List-
ing 7.4, are special relations with a unary range, speciﬁed along with the parameters
(the domain). Functions can be used to represent built in predicates of common
data types. The semantics of a relation or function can be captured within a logical
expression speciﬁed with the hasDeﬁnition statement.

7.2.1.6 Instances of Concepts and Relations

As can be seen in Listing 7.5, it is possible to instantiate both concepts and rela-
tions deﬁned within a WSMO Ontology. When instantiating a concept or relation,
values are assigned to the attributes or parameters of the concept or relation being
instantiated, where the type of the value being assigned conforms to the range of the
attribute or the domain of the parameter. Instances may be deﬁned explicitly within
the ontology, however, in general a link to an external store of instances will be
given when a large number of instances exist.

7.2 Technical Solution
(cid:2)
Class instance

hasAnnotations type annotations
hasType type concept
hasAttributeValues type attributeValue

Class relationInstance

hasAnnotations type annotations
hasType type relation
hasParameterValue type parameterValue

(cid:4)

Listing 7.5 Instance deﬁnitions

(cid:2)
Class axiom sub−Class wsmoElement
hasDeﬁnition type logicalExpression
(cid:4)

Listing 7.6 Axiom deﬁnition

(cid:2)
Class service

hasAnnotations type annotations
hasNonFunctionalProperties type nonFunctionalProperties
importsOntology type ontology
usesMediator type {ooMediator, wwMediator}
hasCapability type capability multiplicity = single−valued
hasInterface type interface

(cid:4)

Listing 7.7 Web service deﬁnition

7.2.1.7 Axioms

113

(cid:3)

(cid:5)

(cid:3)

(cid:5)

(cid:3)

(cid:5)

An axiom, as showed in Listing 7.6, is a logical expression together with its non-
functional properties. Axioms provide a mechanism for adding arbitrary logical ex-
pressions to an ontology, and can be used to reﬁne concepts, relation or function
deﬁnitions, to add arbitrary axiomatic domain knowledge, or to express constraints.

7.2.2 Web Services

Web services are computational entities that provide some functionality that has an
associate value in a given domain. A WSMO Web service is a formal description of
the Web services functionality, in terms of a capability, and the method to interact
with it, in terms of an interface. A formal description of a WSMO Web service using
the MOF notation given in Listing 7.7.

The ontologies that are required in order to deﬁne the service can be imported via
the importsOntology and usesMediator statements. The usesMediator statement
may also be used with a wwMediator (see Sect. 7.2.4.4), in cases where process or
protocol heterogeneity issues need to be resolved.

114
(cid:2)
Class nonFunctionalProperty

hasAnnotations type annotations
hasDeﬁnition type axiom

(cid:4)

Listing 7.8 Non-functional property deﬁnition

(cid:2)
Class capability

hasAnnotations type annotations
hasNonFunctionalProperties type nonFunctionalProperties
importsOntology type ontology
usesMediator type ooMediator
hasPrecondition type axiom
hasAssumption type axiom
hasPostcondition type axiom
hasEffect type axiom

(cid:4)

Listing 7.9 Capability deﬁnition

7 Web Service Modeling Ontology

(cid:3)

(cid:5)

(cid:3)

(cid:5)

7.2.2.1 Non-Functional Properties for Web Services

A service can specify one or more non-functional properties. Listing 7.8 contains
the MOF deﬁnition of a non-functional property in WSMO.

In a nutshell, the non-functional properties captured constraints over the func-
tional and behavioral properties of the service. Typical examples of non-functional
properties include temporal and locative availability of the service, security, rights,
obligations, reliability, performance, etc. Non-functional properties are not speciﬁc
to Web services only, but other WSMO elements descriptions (i.e., goal, mediators,
capabilities and interfaces) can contain non-functional properties descriptions.

7.2.2.2 Capabilities

The capability of the service describes the real value of the service and is described
in MOF in Listing 7.9.

The capability of a service contains a set of axioms that describe the state of the
world before and after the execution of the service. Using the hasPrecondition and
hasPostcondition statements, it is possible to make axiomatic statements about the
expected inputs and outputs of the service, i.e., what information must be available
for the service to be executed and what information will be available after the service
has been executed. The hasAssumption and hasEffect statements can be used to
state the assumed state of the world prior to execution and the guaranteed state of
the world afterwards. The capability of a service can be used by a requester for
discovery purposes, i.e., to determine if the functionality of the service meets the
requesters functional needs.

7.2 Technical Solution
(cid:2)
Class interface

hasAnnotations type annotations
hasNonFunctionalProperties type nonFunctionalProperties
importsOntology type ontology
usesMediator type ooMediator
hasChoreography type choreography
hasOrchestration type orchestration

(cid:4)

Listing 7.10 Interface deﬁnition

(cid:2)
Class choreography

hasAnnotations type annotations
hasStateSignature type stateSignature
hasState type state
hasTransitionRules type transitionRules

(cid:4)

Listing 7.11 Choreography deﬁnition

7.2.2.3 Interfaces

115

(cid:3)

(cid:5)

(cid:3)

(cid:5)

The interface of a service describes how the functionality can be achieved. It is
described in MOF as depicted in Listing 7.10.

The interface of a service provides a dual view on the operational competence of
the service. Using the hasChoreography statement, a decomposition of the capabil-
ity in terms of interaction with the service is provided, while using the hasOrches-
tration statement the capability can be decomposed in terms of the functionality
required from other services in order to realize this service. This corresponds to the
distinction between communication and cooperation. The choreography describes
how to interact with a service, while the orchestration describes how the overall
function of the service is realized through cooperation with other services (see List-
ing 7.11). The interface of a service is presented in a machine processable manner,
allowing for software to automatically determine the behavior of the service and to
reason on it.

Both choreography and orchestration are deﬁned using the same formalism,
based on Abstract State Machines [5]. The choreography of a service is deﬁned
in MOF as follows.

The most important parts of the deﬁnition are the state signature and the transition
rules. The state signature deﬁnes the state ontology used by the service together
with the deﬁnition of the types of modes the concepts and relations may have which
describes the service’s and the requestor’s rights over the instances. The transition
rules express changes of states by changing the set of instances [8].

Applying different transition rules, the choreography evolves from the initial
state which technically is the same as the state signature, if not otherwise speci-
ﬁed, to the ﬁnal state, going through several intermediate states. In the ﬁnal state,
no further updates based on transition rules can be applied.

The orchestration has a similar deﬁnition as the choreography, with the main
difference being that the choreography considers two participants in a conversation,
while the orchestration is a description of the cooperation of multiple participants.

116
(cid:2)
Class goal
hasAnnotations type annotations
hasNonFunctionalProperties type nonFunctionalProperties
importsOntology type ontology
usesMediator type {ooMediator, wwMediator}
requestsCapability type capability multiplicity = single−valued
requestsInterface type interface

(cid:4)

Listing 7.12 WSMO goal class

(cid:2)
Class mediator

hasAnnotations type annotations
hasNonFunctionalProperties type nonFunctionalProperties
importsOntology type ontology
hasSource type {ontology, goal, webService, mediator}
hasTarget type {ontology, goal, webService, mediator}
hasMediationService type {webService, goal, wwMediator}

(cid:4)

Listing 7.13 Mediator deﬁnition

7.2.3 Goals

7 Web Service Modeling Ontology

(cid:3)

(cid:5)

(cid:3)

(cid:5)

A goal speciﬁes the objectives that a client may have when consulting a Web service,
describing aspects related to user desires with respect to the requested functionality
and behavior. Ontologies are used as the semantically deﬁned terminology for goal
speciﬁcation. Goals model the user’s view in the Web service usage process, and
therefore are a separate top-level entity in WSMO. The goal class is described in
Listing 7.12.

7.2.4 Mediators

Mediators describe elements that resolve interoperability problems between differ-
ent elements, e.g., between two ontologies or two services. Mediators are a core
element of WSMO and aim to resolve heterogeneity problems at the data, process
and protocol levels. The deﬁnition of a mediator using the MOF notation is depicted
in Listing 7.13.

Like all WSMO elements, a mediator can deﬁne a set of annotations using the
hasAnnotations statement. Furthermore, the terminology needed from other on-
tologies to deﬁne this mediator can be imported using the importsOntology state-
ment. The source component of a mediator deﬁnes the resources for which the het-
erogeneities are resolved, while the target component deﬁnes the resources that re-
ceives these mediated source components. A mediation service can be used to deﬁne
the facility applied for performing the mediation using the hasMediationService
statement. This service may explicitly link to a Web service description or may link
to a Goal describing the functionality needed, which can then be resolved to a Web
service at runtime using service discovery. There are four types of mediators within
the WSMO metamodel.

7.2 Technical Solution
(cid:2)
Class ooMediator sub−Class mediator
(cid:4)

hasSource type {ontology, ooMediator}

Listing 7.14 ooMediator deﬁnition

(cid:2)
Class ggMediator sub−Class mediator
usesMediator type ooMediator
hasSource type {goal, ggMediator}
hasTarget type {goal, ggMediator}

(cid:4)

Listing 7.15 ggMediator deﬁnition

117

(cid:3)

(cid:5)

(cid:3)

(cid:5)

7.2.4.1 Ontology-to-Ontology Mediators

Ontology-to-Ontology Mediators (ooMediators), as deﬁned in Listing 7.14, provide
a mechanism by which mismatches between two or more ontologies can be resolved.
The source component of an ooMediator is an ontology or another ooMediator,
and the source deﬁnes the resources for which mismatches will be resolved by the
mediator. The target of an ooMediator can be an ontology, goal, Web service or a
mediator, and the target deﬁnes the target component which will receive the results
of the mediation.

As described in Sect. 7.2.1, ooMediators are used across all WSMO top-level
elements within the usesMediator statement in order to import the terminology
required by a resource description whenever there are mismatches between the on-
tologies to be used.

7.2.4.2 Goal-to-Goal Mediators

Goal-to-Goal Mediators (ggMediators), as deﬁned in Listing 7.15, connect goals
to another, allowing for relationships between different goals to be speciﬁed. For
instance, a ggMediator can be used to specify that one goal is equivalent to another
goal, and that the source goal is a reﬁnement of the target.

The source of a ggMediator can be a goal or another ggMediator, which is also
true for the target of a ggMediator. By specifying that a ggMediator is the source or
target, one can build chains of mediators.

7.2.4.3 Web Service-to-Goal Mediators

Web Service-to-Goal Mediators (wgMediators), deﬁned in Listing 7.16, or Goal-to-
Web Service Mediators, provide a mechanism for expressing relationships between
Web services and goals. Primarily, wgMediators are used to pre-link services to
goals, or to cache the results of previously performed discovery actions. For ex-
ample, a wgMediator may be used to express that a given Goal can be totally or
partially fulﬁlled by a given Web service.

118
(cid:2)
Class wgMediator sub−Class mediator
usesMediator type ooMediator
hasSource type {webService, goal, wgMediator, ggMediator}
hasTarget type {webService, goal, ggMediator, wgMediator}

(cid:4)

Listing 7.16 wgMediator deﬁnition

(cid:2)
Class wwMediator sub−Class mediator
usesMediator type ooMediator
hasSource type {webService, wwMediator}
hasTarget type {webService, wwMediator}

(cid:4)

Listing 7.17 wwMediator deﬁnition

7 Web Service Modeling Ontology

(cid:3)

(cid:5)

(cid:3)

(cid:5)

7.2.4.4 Web Service-to-Web Service Mediators

Web Service-to-Web Service Mediators (wwMediators), deﬁned in Listing 7.17,
provide a mechanism for expressing relationships between Web services. These
relationships could include stating that two Web services provide equivalent func-
tionality, a group of Web services provides equivalent functionality to another Web
service, or that one Web service is a reﬁnement of another.

wwMediators can also be used to establish interoperability between Web services
in cases where they would otherwise be not interoperable, i.e., a wwMediator could
be used to specify a mediation between the choreography of two Web services,
where mediation can involve the data, protocol or process levels.

7.3 Extensions

In this section, we brieﬂy introduce a number of extensions for modeling services
that were inspired by the WSMO approach. One characteristic that is common to
all classical approaches for Semantic Web Services, including WSMO, is the top-
down modeling. However, top-down modeling decouples the Semantic Web Ser-
vice model from the actual syntactic description which contains where the service
is located and how exactly it can be invoked. Another approach that gained more
momentum is the bottom-up approach for modeling that is adopted by a number of
extensions for modeling services.

Current extensions to WSMO conceptual model include those that are follow-
ing the bottom-up path such as WSMO-Lite, a lightweight ontology for service
semantics, Semantic Annotations for WSDL (SAWSDL) that provides an semantic
annotation mechanisms allowing the speciﬁcation of pointers to semantic concepts
from within a syntactic description of a WSDL service and MicroWSMO that ba-
sically has the same purpose as SAWSDL but for RESTful services. SAWSDL and
MicroWSMO build on top of syntactic representations formalisms, namely WSDL
and hRESTS. The approaches mentioned above are known as lightweight for ser-
vices given the fact that they “add a bit of semantics” on top of existing non-semantic

7.4 Illustration by a Larger Example

119

standards. More details about each of the mentioned lightweight approaches for Se-
mantic Web Services are provided in Chap. 12. In the rest of this section, we brieﬂy
summarize the main features of the lightweight approaches.

WSMO-Lite is a simple, yet powerful ontology that can be used to model all
important aspects of a service. It distinguishes between four type of semantics,
i.e., functional, non-functional, behavioral, and information model. Furthermore,
WSMO-Lite provides an RDF Schema ontology to express the four types of seman-
tics mentioned previously. The WSMO-Lite ontology can be used to semantically
annotate both WSDL-based and RESTful-based services. In the former case, the
approach used to provide hooks for attaching semantics is SAWSDL, while the later
is MicroWSMO.

SAWSDL is a set of extensions for WSDL.1 The two major constructs provided
by SAWSDL are model references that can be used to point to semantic concepts
and schema mappings that can be used to specify data transformations between the
XML data structure of messages and the associated semantic model. SAWSDL by
itself, however, does not specify any actual types of semantics.

MicroWSMO can be seen as a direct realization of SAWSDL annotations over
hRESTS. As SAWSDL, MicroWSMO provides a set of elements that can be used
to point to semantic descriptions. These include model, lowering and lifting which
can be associated with the underlying hREST description.

7.4 Illustration by a Larger Example

In this section, we use the “Virtual Traveling Agency” scenario introduced in
Chap. 4 to exemplify how services can be semantically annotated using the WSMO
approach. In this scenario, a customer uses the Virtual Traveling Agency (VTA) ap-
plication to access eTourism services. The reminder of this section illustrates how a
concrete service offers online train booking tickets, as well as how related ontolo-
gies, goals, and mediators can be modeled using WSMO. We use the Web Service
Modeling Language (WSML) to represent all of these elements. The modeling ex-
ample presented here is partially based on content available in [9].

7.4.1 Ontologies

We use the following domain ontologies: International Train Ticket, Temporal,
Locative, Price, Quality, Provider, Measures.

Six of the ontologies mentioned above, namely Temporal, Locative, Price,
Quality, Provider, Measures, are generic ontologies containing non-functional
properties models. These ontologies have been deﬁned in [10].

1Web Services Description Language, http://www.w3.org/TR/wsdl20/.

120

7 Web Service Modeling Ontology

The “International Train Ticket” ontology deﬁnes a train trip and the surrounding
concepts shown in Listing 7.18. The deﬁnition of the ontology is based on the travel
itinerary ontology from the DAML ontology library.2 This ontology captures infor-
mation about travel itineraries for trips by plane. Our ontology reuses the itinerary
and ﬂight concepts and adapts them to deﬁne train trips, also introducing new con-
cepts such as the train station. The International Train Ticket ontology also makes
use of the person ontology3 which deﬁnes a subset of vCard. The person concept is
used to deﬁne the passenger information for an itinerary.

7.4.2 Goals

Goals denote what a user wants as the result of a Web service. To exemplify how
goals are modeled in WSMO, we deﬁne in Listing 7.19 a generic goal for buying
a ticket for any kind of trip. Please note that in WSMO, goals can be deﬁned on
different levels of granularity. Through ggMediators, new, more speciﬁc goals can
be created out of generic existing goals. Generic goals can also be thought of as
being pre-deﬁned in a speciﬁc application context, from which concrete Goals can
be generated.

7.4.3 Web Services

For exempliﬁcation, let us consider an end-user service (a service with which the
user interacts) for purchasing international train tickets offered by the Austrian na-
tional train operator OEBB; this Web service can be composed of other Web ser-
vices, each for the search and purchasing facility of international train tickets. This
setting allows for the correct modeling of all notions of a WSMO Web service de-
scription: a capability of the end-user service and its choreography for user-service
interaction, as well as the orchestration which incorporates the aggregated Web ser-
vices.

A Web service capability in WSMO is described by pre- and postconditions, as-
sumptions and effects, as deﬁned in [7]. Listing 7.20 shows the OEBB Web service.
The capability of the OEBB Web service includes:
• Precondition

This input has to include information about the buyer, a train trip that a ticket
is to be purchased for, and information on the passenger for whom the ticket
shall be valid. To be a valid input, the following restrictions are deﬁned for the
trip: the start and end locations are restricted to stations in Austria or Germany;

2http://www.daml.org/ontologies/ontologies.html.
3http://daml.umbc.edu/ontologies/ittalks/person.

7.4 Illustration by a Larger Example

(cid:2)

121

(cid:3)

wsmlVariant _"http://www.wsmo.org/wsml/wsml−syntax/wsml−rule"

namespace { _"http://www.wsmo.org/ontologies/trainConnection",

dc _"http://purl .org/dc/elements/1.1#",
prs _"http://www.wsmo.org/2004/d3/d3.3/v0.1/20041008/resources/owlPersonMediator.wsml"
xsd _"http://www.w3.org/2001/XMLSchema#",
wsml _"http://www.wsmo.org/wsml/wsml−syntax#",
loc _"http://www.wsmo.org/ontologies/nfp/locativeNFPOntology#",
temp _"http://www.wsmo.org/ontologies/nfp/temporalNFPOntology#",
qua _"http://www.wsmo.org/ontologies/nfp/qualityNFPOntology#",
po _"http://www.wsmo.org/ontologies/nfp/providerNFPOntology#",
prc _"http://www.wsmo.org/ontologies/nfp/priceNFPOntology#",
mes _"http://www.wsmo.org/ontologies/nfp/measuresNFPOntology#" }

ontology _"http://www.wsmo.org/ontologies/trainConnection"

annotations

dc#title hasValue "International Train Ticket Ontology"
dc#creator hasValue "STI Innsbruck"
dc#subject hasValues {"Train", " Itinerary " , "Train Connection", Ticket"}
dc#description hasValue "Domain Ontology International Train Ticket"
dc#format hasValue "text/html"
dc#identiﬁer hasValue _"http://www.wsmo.org/ontologies/trainConnection"
dc: contributor hasValues {"Michael Stollberg", "Ruben Lara",
"Holger Lausen", "Ioan Toma"}
dc#language hasValue "en−US"
wsml#version hasValue "Revision : 2.0"

endAnnotations

importsOntology {_" http://www.wsmo.org/ontologies/nfp/locativeNFPOntology",

_"http://www.wsmo.org/ontologies/nfp/temporalNFPOntology"}

usedMediators

{_" http://www.wsmo.org/2004/d3/d3.3/v0.1/20041008/resources/owlPersonMediator.wsml"}

concept station subConceptOf loc#GeoLocation

annotations

dc#description hasValue "Train station "

endAnnotations
code ofType _string

annotations

dc#description hasValue "Code of the station"

endAnnotations

borderToCountry ofType loc#Border

annotations

dc#description hasValue "For stations located at the border"

endAnnotations

concept ticket

annotations

dc#description hasValue "a ticket

for an itinerary "

endAnnotations
itinerary ofType itinerary
provider ofType po#Provider
price ofType prc#AbsoultePrice

concept

itinerary
annotations

dc#description hasValue "An itinerary between two locations"

endAnnotations
passenger ofType prs#person

(cid:4)

(cid:5)

Listing 7.18 Domain ontology “International Train Ticket”

122

(cid:2)

7 Web Service Modeling Ontology
(cid:3)

annotations

dc#description hasValue "prs#person is a subset of vCard (http://www.ietf.org/rfc/

rfc2425.txt)"

endAnnotations

recordLocatorNumber ofType _string
trip ofType trip

concept trip

start ofType loc#LocativeEntity
end ofType loc#LocativeEntity
via ofType loc#RouteSpeciﬁcation
departure ofType temp#TimePoint
arrival ofType temp#TimePoint
duration ofType temp#TimeInterval
distance ofType mes#Distance

concept trainTrip subConceptOf trip

annotations

dc#description hasValue "A train trip "

endAnnotations
start ofType station
end ofType station
via ofType station
seat ofType _string
train ofType _string
class ofType _string

axiom departureBeforeArrival

annotations

dc#description hasValue " Integrity Constraint: departure has to be before arrival "

endAnnotations
deﬁnedBy
!− ?T[

departure hasValue ?D,
arrival hasValue ?A

]memberOf trip
and ?A <= ?D.

axiom startNotEqualEnd
annotations

dc#description hasValue " Integrity Constraint: the start and end of a trip have to be

different "

endAnnotations
deﬁnedBy
!− ?T[

start hasValue ?Start,
end hasValue ?End

]memberOf trip
and ?Start = ?End.

(cid:4)

Listing 7.18 (Continued)

(cid:5)

the departure date for the trip has to be after the current date; and the payment
method of the buyer has to be a credit card.

• Assumption

The credit card submitted as input has to be valid (not expired).

• Postcondition

The service returns a purchase for train tickets valid in Austria and Germany by
the OEBB as the provider, with payment by credit card only.

• Effect

7.4 Illustration by a Larger Example

(cid:2)

123

(cid:3)

wsmlVariant _"http://www.wsmo.org/wsml/wsml−syntax/wsml−rule"

namespace {

_"http://www.wsmo.org/example/VTA/goals/GeneralTrainTrip#",
dc _"http://purl .org/dc/elements/1.1#",
tc _"http://www.wsmo.org/ontologies/trainConnection#",
temp _"http://www.wsmo.org/ontologies/nfp/temporalNFPOntology#",
loc _"http://www.wsmo.org/ontologies/nfp/locativeNFPOntology#",
pay _"http://www.wsmo.org/ontologies/nfp/paymentNFPOntology#",
xsd _"http://www.w3.org/2001/XMLSchema#",
wsml _"http://www.wsmo.org/wsml/wsml−syntax#",
po _"http://www.wsmo.org/ontologies/purchase#"}

goal "http://www.wsmo.org/example/VTA/goals/GeneralTrainTrip.wsml"

annotations

dc#title hasValue "Buying a ticket online"
dc#subject hasValues {"Tickets", "Online Ticket Booking", " trip " }
dc#creator hasValue "STI Innsbruck"
dc#description hasValue "Express the goal of buying a ticket
dc#contributor hasValues {"Michael Stollberg", "Ruben Lara", "Holger Lausen", "Ioan Toma"}
dc#format hasValue "text/html"
dc#language hasValue "en−US"
dc#coverage hasValues {tc#austria, tc#germany}
dc#version hasValue "Revision : 2.0"

for a trip "

endAnnotations

importsOntology {_"http://www.wsmo.org/ontologies/trainConnection#",
_"http://www.wsmo.org/ontologies/nfp/locativeNFPOntology#",
_"http://www.wsmo.org/ontologies/purchase#"}

postcondition

axiom purchasingTicketForTrip

annotations

dc#description hasValue "This goal expresses the general desire of buying a ticket

for
any kind of

itinerary . "

endAnnotations
deﬁnedBy

exists ?Purchase, ?Purchaseorder, ?Buyer, ?Product, ?PaymentMethod, ?Ticket,

?Itinerary, ?Passenger, ?Trip

(?Purchase memberOf po#purchase[

po#purchaseorder hasValue ?Purchaseorder,
po#buyer hasValue ?Buyer

] and
?Buyer memberOf po#buyer and
?Purchaseorder memberOf po#purchaseOrder[
po#product hasValues {?Product},
po#payment hasValue ?PaymentMethod

] and
?PaymentMethod memberOf po#paymentMethod and
?Product memberOf po#product[

po#item hasValues {?Ticket}

] and
?Ticket memberOf tc#ticket[

tc#itinerary hasValue ?Itinerary

] and
?Itinerary memberOf tc#itinerary[

tc#passenger hasValue ?Passenger,
tc#trip hasValue ?Trip

(cid:4)

Listing 7.19 Goal—buying a ticket online

(cid:5)

124

(cid:2)

7 Web Service Modeling Ontology
(cid:3)

] and
?Passenger memberOf tc#Person and
?Trip memberOf tc#trip) .

effect

axiom havingTradeForTrip

annotations

dc#description hasValue "The goal effect is to get the purchased ticket delivered

to the buyer."

endAnnotations
deﬁnedBy

exists ?Delivery, ?Product, ?Buyer, ?Ticket
(
?Delivery memberOf po#delivery[

po#deliveryItem hasValues {?Product},
po#receiver hasValue ?Buyer

] and
?Product memberOf po#product[

po#item hasValues {?Ticket}

] and
?Buyer memberOf po#buyer and
?Ticket memberOf tc#ticket
) .

(cid:4)

Listing 7.19 (Continued)

(cid:5)

The sold ticket is delivered to the buyer’s shipping address, either by a drop ship
carrier or via online delivery.

7.4.4 Mediators

As mentioned in Sect. 7.2.4, mediators play a signiﬁcant role in the WSMO mod-
eling as they are responsible for solving the heterogeneity problem. WSMO deﬁnes
four types of mediators, namely ooMediators, ggMediators, wgMediators and ww-
Mediators. Listing 7.21 contains a description of an ooMediator that imports other
ontologies or ooMediators into WSMO entities and resolves possible terminology
mismatches. If no mismatch has to be resolved, the syntactical simpliﬁcation “im-
portOntologies” can be used.

7.5 Summary

Semantic Web Services are one of the most promising research directions to im-
prove the integration of applications within and across enterprise boundaries. In this
context, this chapter provided an overview of one of the most important approaches
to Semantic Web Services, namely the Web Service Modeling Ontology. We ar-
gue that, in order for Semantic Web Services to succeed, a fully ﬂedged framework
needs to be provided: starting with a conceptual model, continuing with a formal

7.5 Summary

(cid:2)

125

(cid:3)

wsmlVariant _"http://www.wsmo.org/wsml/wsml−syntax/wsml−rule"

namespace {

_"http://www.wsmo.org/example/VTA/services/OEBBService.wsml#",
dc _"http://purl .org/dc/elements/1.1#",
tc _"http://www.wsmo.org/ontologies/trainConnection#",
temp _"http://www.wsmo.org/ontologies/nfp/temporalNFPOntology#",
loc _"http://www.wsmo.org/ontologies/nfp/locativeNFPOntology#",
pay _"http://www.wsmo.org/ontologies/nfp/paymentNFPOntology#",
xsd _"http://www.w3.org/2001/XMLSchema#",
wsml _"http://www.wsmo.org/wsml/wsml−syntax#",
po _"http://www.wsmo.org/ontologies/purchase#"}

webservice
" http://www.wsmo.org/example/VTA/services/OEBBService.wsml"

annotations

dc#title hasValue "OEBB Online Ticket Booking Web Service"
dc#creator hasValue "STI Innsbruck"
dc#description hasValue "web service for booking online train tickets for Austria and

Germany"

dc#contributor hasValues {"Michael Stollberg", "Ruben Lara", "Holger Lausen", "Ioan Toma"}
dc#format hasValue "text/html"
dc#language hasValue "en−US"
dc#coverage hasValues {tc#austria, tc#germany}
dc#version hasValue "Revision : 2.0"

endAnnotations

importsOntology {_"http:://www.wsmo.org/ontologies/trainConnection#",
_"http://www.wsmo.org/ontologies/nfp/temporalNFPOntology#",
_"http://www.wsmo.org/ontologies/nfp/locativeNFPOntology#",
_"http://www.wsmo.org/ontologies/nfp/paymentNFPOntology#",
_"http://www.wsmo.org/ontologies/purchase#"}

capability oebbWSCapability

precondition

axiom oebbWSprecondition

annotations

dc#description hasValue "The oebbWSprecondition puts the following

conditions ont
the input :
address, and credit card as a paymentMethod, and trip with the start−

it has to include a buyer with a billTo and a shipTo

and

end− location have to be in Austria or in Germany, and the departure

date

has to be later than the current date. "

endAnnotations

deﬁnedBy

forAll ?Buyer, ?BuyerBilltoAddress, ?BuyerShiptoAddress, ?BuyerPaymentMethod,
?Trip , ?Start, ?End, ?Departure (

?Buyer memberOf po:buyer[

po#billToAddress hasValue ?BuyerBilltoAddress,
po#shipToAddress hasValue ?BuyerShiptoAddress,
po#hasPaymentMethod hasValues {?BuyerPaymentMethod}

] and
?BuyerBilltoAddress memberOf loc#Address and
?BuyerShiptoAddress memberOf loc#Address and
?BuyerPaymentMethod memberOf pay#CreditCard and
?Trip memberOf tc#trainTrip[

tc#start hasValue ?Start,
tc#end hasValue ?End,
tc#departure hasValue ?Departure

(cid:5)

(cid:4)

Listing 7.20 OEBB web service for booking online train tickets for Austria and Germany

126

(cid:2)

7 Web Service Modeling Ontology

(cid:3)

] and
(?Start.locatedIn = austria or ?Start.locatedIn = germany) and
(?End.locatedIn = austria or ?End.locatedIn = germany) and
temp#after(?Departure,currentDate)
) .

postcondition

axiom oebbWSpostcondition

annotations

dc#description hasValue "the output of the service is a purchase for a

ticket

for

train trips wherefore

the start − and end− location have to be in Austria or in Germany and
the departure date has to be later than the current Date."

endAnnotations
deﬁnedBy
forAll ?Purchase, ?Seller, ?OEBBContactInformation, ?Purchaseorder,

?PaymentMethod, ?Product, ?Ticket,

?Itinerary , ?Trip , ?Start, ?End

(

?Purchase memberOf po#purchase[

purchaseorder hasValue ?Purchaseorder,
seller hasValue ?Seller

] and
?Seller memberOf po#seller[
contactInformation hasValue ?OEBBContactInformation,
acceptsPaymentMethod hasValues {?PaymentMethod}
] and
?OEBBContactInformation memberOf po#contactInformation[
name hasValue "Oesterreichische Bundesbahn",
emailaddress hasValue "ofﬁce@oebb.at",
physicalAddress hasValue ?OEBBAddress

] and
?OEBBAddress memberOf loc#Address[

streetAddress hasValue "Hauptfrachtenbahnhof 4",
city hasValue innsbruck,
country hasValue austria

] and
?Purchaseorder memberOf po#purchaseOrder[

product hasValues {?Product},
payment hasValue ?PaymentMethod

] and
?PaymentMethod memberOf pay#CreditCard and
?Product memberOf po#product[

item hasValues {?Ticket}

] and
?Ticket memberOf tc#ticket[

itinerary hasValue ?Itinerary

] and
?Itinerary memberOf tc#itinerary[
trip hasValue ?Trip

] and
?Trip memberOf tc#trainTrip[
start hasValue ?Start,
end hasValue ?End,
departure hasValue ?Departure

] and

(?Start.locatedIn = austria or ?Start.locatedIn = germany) and
(?End.locatedIn = austria or ?End.locatedIn = germany) and

temp#after(?Departure,currentDate)

(cid:4)

) .

Listing 7.20 (Continued)

(cid:5)

7.5 Summary

(cid:2)

effect

axiom oebbWSeffect

annotations

dc:description hasValue "the sold ticket
drop ship carrier or via email."

is delivered to the buyer via a

endAnnotations
deﬁnedBy
forAll ?Delivery, ?Product, ?Buyer, ?BuyerShipToAddress, ?Seller,

?OEBBContactInformation, ?OEBBAddress

(
(( ?Delivery memberOf po:dropShipDelivery[

deliveryItem hasValues {?Product},
receiver hasValue ?Buyer,
sender hasValue ?Seller,
carrier hasValue PostAt

]) or
(?Delivery memberOf po#onlineDelivery[

deliveryItem hasValues {?Product},
receiver hasValue ?Buyer,
onlineDeliveryMethod hasValue "email"

]) ) and
?Product memberOf po#product[

item hasValues {?Ticket}

] and
?Buyer memberOf po#buyer[

shipToAddress hasValue ?BuyerShipToAddress

] and
?BuyerShipToAddress memberOf loc#Address and
?Seller memberOf po#seller[

contactInformation hasValue ?OEBBContactInformation
] and
?OEBBContactInformation memberOf po#contactInformation[
name hasValue "Oesterreichische Bundesbahn",
emailaddress hasValue "ofﬁce@oebb.at",
physicalAddress hasValue ?OEBBAddress

] and
?OEBBAddress memberOf loc#Address[

streetAddress hasValue "Hauptfrachtenbahnhof 4",
city hasValue innsbruck,
country hasValue austria

]

) .

interface oebbWSInterface

annotations

dc:description hasValue "describes the Interface of Web service"

endAnnotations
choreography ∗∗∗
orchestration ∗∗∗

(cid:4)

Listing 7.20 (Continued)

127
(cid:3)

(cid:5)

language to provides formal syntax and semantics (based on different logics in or-
der to provide different levels of logical expressiveness) for the conceptual model,
and ending with an execution environment that glues together all components that
use the language for performing various tasks that would eventually enable automa-
tion of the service. The WSMO approach tackles, in a unifying manner, all the
aspects of such a framework, and potentially provides the conceptual basis and the
technical means for realizing Semantic Web Services: it deﬁnes a conceptual model

128

(cid:2)

7 Web Service Modeling Ontology
(cid:3)

wsmlVariant _"http://www.wsmo.org/wsml/wsml−syntax/wsml−rule"

namespace {

_"http://www.wsmo.org/example/VTA/mediators/owlAddressMediator#",
dc _"http://purl .org/dc/elements/1.1#",
loc _"http://www.wsmo.org/ontologies/nfp/locativeNFPOntology#",
wsml _"http://www.wsmo.org/wsml/wsml−syntax#"}

ooMediator
" http://www.wsmo.org/example/VTA/mediators/owlAddressMediator.wsml"

annotations

dc#title hasValue "OO Mediator importing the OWL Factbook ontology to WSML"
dc#creator hasValue "STI Innsbruck"
dc#description hasValue "Mediator to import an OWL address ontology into a WSML locations

ontology"

dc#contributor hasValues {"Michael Stollberg", "Ruben Lara", "Holger Lausen", "Ioan Toma"}
dc#format hasValue "text/html"
dc#language hasValue "en−US"
dc#version hasValue "Revision : 2.0"

endAnnotations

importsOntology {_"http:://www.wsmo.org/ontologies/trainConnection#",
_"http://www.wsmo.org/ontologies/nfp/temporalNFPOntology#",
_"http://www.wsmo.org/ontologies/nfp/locativeNFPOntology#",
_"http://www.wsmo.org/ontologies/nfp/paymentNFPOntology#",
_"http :://www.wsmo.org/ontologies/purchase#"}

source _"http://daml.umbc.edu/ontologies/ittalks/address"

target _"http://www.wsmo.org/ontologies/nfp/locativeNFPOntology"

useService
_"http://138.232.65.151:8080/TranslatorService/OWL2WSML/"

(cid:4)

(cid:5)

Listing 7.21 OO-Mediator “importing the OWL address ontology to the location ontology”

(WSMO) for deﬁning the basic concepts of Semantic Web Services, a formal family
of languages (WSML) (see Chap. 8) which provides a formal syntax and seman-
tics for WSMO by offering different variants based on different logics in order to
provide different levels of logical expressiveness (thus allowing different trade-offs
between expressivity and computability), and an execution environment (WSMX)
(see Chap. 9) which provides a reference implementation for WSMO and interoper-
ation of Semantic Web Services. This chapter has focused on the WSMO conceptual
model. The following two chapters discuss the other constituents of the approach,
namely the formal family of languages, WSML, and the execution environment,
WSMX. To conclude, the clean conceptual model and the design principles of the
Web that underly the approach, make WSMO a key contribution towards realizing
the vision of Semantic Web Services and Semantically Enabled Service-oriented
Architectures.

7.6 Exercises

Exercise 1 Extend the WSMO ontology available in Listing 7.18 with other el-
ements that capture knowledge about bus transportation. You should add at least

References

129

one example of concept, relation, function, concept instance, relation instance, and
axiom.

Exercise 2 Consider a bus transportation company as one company that provides
tourism services as part of the VTA scenario. Create a WSMO description for the
bus transportation service. The resulting description should include description of
the capability, including pre-conditions, post-conditions, assumptions, and effects.
Explain in your own words what the difference between these elements is using your
example.

Exercise 3 Discuss differences between a service and a Web service in the WMSO
approach. Give an example of service and one of Web service using in the hotel
booking sub-domain of the VTA scenario.

References

1. Bellwood, T., Clément, L., Ehnebuske, D., Hately, A., Hondo, M., Husband, Y.L.,
Januszewski, K., Lee, S., McKee, B., Munter, J., von Riegen, C.: UDDI Version 3.0 (2002)
2. Berners-Lee, T., Hendler, J., Lassila, O.: The Semantic Web. Scientiﬁc American
284(5), 34–43 (2001). http://www.sciam.com/article.cfm?articleID=00048144-10D2-1C70-
84A9809EC588EF21&ref=sciam

3. Christensen, E., Curbera, F., Meredith, G., Weerawarana, S.: Web Services Description Lan-

guage (WSDL) 1.1. (2001). http://www.w3.org/TR/wsdl

4. Fensel, D., Bussler, C.: The Web Service Modeling Framework (WSMF). Electronic Com-

merce Research and Applications 1(2), 113–137 (2002)

5. Gurevich, Y.: Evolving Algebras 1993: Lipari guide. In: Börger, E. (ed.) Speciﬁcation and
Validation Methods, pp. 9–37. Oxford University Press, London (1994). http://citeseer.ist.
psu.edu/gurevich93evolving.html

6. Object Management Group Inc. (OMG): Meta Object Facility (MOF) Speciﬁcation v1.4.

(2002). http://www.omg.org/technology/documents/formal/mof.htm

7. Roman, D., Lausen, H. (eds.): U.K.: Web Service Modeling Ontology (WSMO). Working

Draft D2v1.2, WSMO, (2005). Available from http://www.wsmo.org/TR/d2/v1.2/

8. Roman, D., Scicluna, J., Nitzsche, J.: Ontology-based choreography. Deliverable D14v1.0.,

WSMO (2007). Available from http://www.wsmo.org/TR/d14/v1.0/

9. Stollberg, M., Lausen, H., Keller, U., Zaremba, M., Haller, A., Fensel, D., Kifer, M.: D3.3 v0.1
WSMO use case virtual travel agency. Working Draft D3.3v0.1, WSMO (2004). Available
from http://www.wsmo.org/2004/d3/d3.3/v0.1/

10. Toma, I., Foxvog, D.: Non-functional properties in Web services. Working draft, Digital En-
terprise Research Institute (DERI), August (2006). Available from http://www.wsmo.org/TR/
d28/d28.4/v0.1/

11. W3C: SOAP Version 1.2 Part 0: Primer (2003)
12. Weibel, S., Kunze, J., Lagoze, C., Wolf, M.: Dublin Core metadata for resource discovery.

RFC 2413, IETF (1998)

Chapter 8
The Web Service Modeling Language

Abstract Several languages have been developed to describe ontologies, e.g.,
OWL, KIF, OIL, F-Logic. They have different characteristics and different under-
lying logics that make them more suitable to certain types of use, e.g., OWL is
perfect for describing hierarchies. In some cases, they have been used to describe
Semantic Web Services, e.g., OWL-S is an ontology expressed in OWL to describe
Semantic Web Services, but they have not been designed with this purpose in mind.
In this chapter, we provide an introduction to the Web Service Modeling Language
(WSML), a language for the speciﬁcation of different aspects of Semantic Web Ser-
vices. First, we discuss the motivation behind the introduction of WSML, then we
analyze the WSML language in detail providing examples for each of its constructs.
This analysis is followed by a large example showing a fully ﬂedged set of Semantic
Web Services descriptions based on WSML. Finally, we provide a set of exercises
to practice WSML.

8.1 Motivation

In the previous chapters, we have discussed the importance of Semantic Web Ser-
vices to enable automate tasks, such as discovery, mediation, selection, composition,
and invocation of services. To achieve this vision, providing support for Web ser-
vices description is fundamental. Speciﬁcally, in Chap. 7, we introduced the Web
Service Modeling Ontology (WSMO). WSMO identiﬁes the conceptual elements
required for such descriptions, thereby providing a framework for Web service de-
scription. Nevertheless, nothing was said about a concrete formal language to sup-
port such description and the properties it should possess. In this section, we discuss
these requirements in light of the WSMO framework, current available ontology
languages and logic frameworks.

8.1.1 Principles of WSMO

The Web Service Modeling Ontology WSMO [13, 29], introduced in detail in
Chap. 7, provides a conceptual model for the description of Web services. A lan-
guage to support a conceptual framework needs to reﬂect its fundamental principles.

D. Fensel et al., Semantic Web Services,
DOI 10.1007/978-3-642-19193-0_8, © Springer-Verlag Berlin Heidelberg 2011

131

132

8 The Web Service Modeling Language

In particular, for the discussion in this chapter, the most relevant WSMO principles
are: Web Compliance, Ontology-based, Separation of requester and provider
roles, and Strict decoupling of resources. All of the principles were extensively
explained in the previous chapter.

Following this prior discussion, WSMO further identiﬁes four main top-level

elements: ontologies, Web services, goals, and mediators.

A language that implements WSMO should support the formal description of the
aforementioned elements, while simultaneously respecting the WSMO fundamental
principles. Furthermore, in order to properly support WSMO concepts of service
and goals, a language needs to be able to describe both functional and behavioral,
as well as non-functional aspects of every element.

8.1.2 Logics Families and Semantic Web Services

The reference language proposed by W3C to deﬁne ontologies, the Web Ontology
Language (OWL) [22], is based on Description Logics (DLs) [1]. Description Log-
ics is a family of logic-based knowledge representation formalisms that corresponds
to a 2-variable decidable fragment of First Order Logic.

Practical experience in building applications has revealed several shortcomings
of OWL, and hence Description Logics for modeling knowledge. In particular, some
of the most prominent features missing in OWL are [25]:
• Higher Relational Expressivity. While OWL allows describing the concepts
through a rich set of primitives, its capability to express knowledge about roles is
very reduced, and does not correspond to the sets of primitives required by real
world applications. Roles in Description Logic (DL) can be described only as
pairs since it is a 2-variable based logic, while in many applications more com-
plex roles require more complex deﬁnitions. For example, the knowledge that “an
uncle of a person is a male sibling of one of the parents of that person” cannot be
formalized in DLs.

• Polyadic Predicates. OWL supports only unary and binary predicates, while in
many real world applications, n-ary predicates are required. For example, the
predicate “the individual X bought the book Y from the seller Z” is a 3-ary pred-
icate. This predicate cannot be directly modeled in DLs. One possible solution is
to create a fourth term K, representing the predicate and linking the other terms
to it. (i.e., “the purchase K has buyer X, seller Z and object Y”).

• Close-World Reasoning. OWL and DLs are based on the Open-World Assump-
tion (OWA), i.e., what is not currently known to be true is undecided (neither
true nor false). This assumption often collides with the needs of applications for
which the Closed-World Assumption (i.e., what is not currently known to be true
is false) is more appropriate. Let us consider a relation that represents the train
connection between two cities and instances of this relation only for the actual
existing connections; in the ﬁrst case, when there is no instance of this relation
between two cities, we cannot say whether the two cities are connected or not; in
the second case, we are sure that the two cities are not connected by any train.

8.1 Motivation

133

• Integrity Constraints. Integrity constraints cannot be easily expressed in OWL.
This is due the fact that OWL adopts the Open-World Assumption and does not
adopt the Unique Names Assumption (UNA) (i.e., two resources with different
identiﬁers are different resources). For example, if we consider a formalization
where we deﬁne the concept “ﬂight seat” that has a property called “hasPassen-
ger” with only one value of type passenger, then if we have two people (e.g.,
Mary and John) assigned to the same seat by mistake, in OWL this means that
Mary and John are the same individual.

• Modeling Exceptions. In many practical situations, the exceptions modeling is
crucial. For example, most birds are able to ﬂy, but exceptionally some of them do
not have this ability. Such a domain cannot be modeled in OWL: the axioms Bird
and CanFly, CannotFly and Bird, and CanFly or CannotFly make the concept
CanFly unsatisﬁable.

The above list provides some insight into the limitations of OWL. Beside these
limitations, we can also observe that in many situations, in order to model the do-
main of an application, we need to be able to express complex rules. OWL by itself
does not provide any rule deﬁnition support. In the context of Web services, rules
are important to enable the formal deﬁnition of services functionalities like “this
service can be invoked only if the credit card is valid, and a credit card is valid
if it is not expired and its monthly maximum credit amount was not reached”. To
provide rule support for OWL, the Semantic Web Rule Language (SWRL) [17] was
deﬁned. SWRL is a simple extension of OWL with material (ﬁrst-order) implication
and due to the straightforward way in which the rules are integrated with OWL, it is
trivially undecidable (close-world reasoning). Furthermore, SWRL cannot address
tasks such as integrity constraints, since it was designed as a ﬁrst-order language.

A proper combination of Description Logics with Logic Programming, enables
the resolution of these problematics. At the same time, it constitutes a useful formal
language paradigms for ontology description and knowledge representation on the
Semantic Web [19]. The formal properties, as well as reasoning algorithms, for both
paradigms have been thoroughly investigated in the respective research communi-
ties (Description Logic and Logic Programming), and efﬁcient reasoning imple-
mentations are available for both paradigms. A formal language for WSMO should
leverage the research that has been done in both areas, and the implementations that
are available, by catering for these language paradigms.

The difference in the expressiveness and underlying assumptions should be over-
come by deﬁning a means for interaction between descriptions. On the one hand, it is
desirable to use a common subset of both paradigms for such interaction (cf. [14])
so that it is not necessary to compromise on computational properties and so that
existing implementations may be used. On the other hand, using a common subset
requires compromising on expressiveness, which is not desirable in many situations;
a common superset would include the expressiveness of both paradigms, but would
require compromising on computational properties such as decidability (cf. [21]).

In the next section, we illustrate, based upon the previous discussion, how the

WSML language was designed.

134

8 The Web Service Modeling Language

Fig. 8.1 The WSML variants [15]

8.2 Technical Solution

A formal description of Web services, as well as user goals, has three major char-
acteristics: static background knowledge in the form of ontologies, the functional
description of the service (suitable for discovery and high-level composition), and
the behavioral description of the service (suitable for selection, mediation, compo-
sition, and invocation). In this chapter, we present a language framework addressing
all three aspects—the Web Service Modeling Language (WSML) that constitutes
the formal grounding of the Web Service Modeling Ontology introduced in Chap. 7.
In order to address the problem of ontology description, the Web Service Mod-
eling Language incorporates the Description Logic and Logic Programming formal
language paradigms and the RDF Schema and OWL Semantic Web ontology lan-
guages. With regards to the functional description of services, WSML relies upon
a ﬂexible framework based on Abstract State Spaces, which can be combined with
a number of logical languages. Finally, WSML addresses the problem of behav-
ioral description with a ﬂexible expressive language that has its conceptual roots in
Abstract State Machines.

In the following paragraphs, we discuss these aspects in more details.

8.2.1 WSML Language Variants

In Sect. 8.1.2, we discussed the need for a formalism based on both Description
Logic (DL) and Logic Programming (LP) paradigms. WSML responds to this need
by incorporating a number of different language variants corresponding to DL
and LP.

Figure 8.1 shows the WSML language variants and their inter-relationships. The
variants differ in logical expressiveness and underlying language; they allow users

8.2 Technical Solution

135

to make a trade-off between the expressiveness of a variant and the complexity of
reasoning for ontology modeling on a per-application basis. Additionally, different
variants are more suitable for different kinds of reasoning and representation.
• WSML-Core is at the intersection between the Description Logic S H I Q and
Horn Logic, also known as Description Logic Programs [14], and it has the low-
est expressive power of the WSML variants. Every WSML-Core description is
also a WSML-DL and WSML-Flight/Rule description. The main features of the
language are the support for modeling classes, attributes, binary relations and in-
stances. Furthermore, the language supports class hierarchies, as well as relation
hierarchies. WSML-Core provides support for datatypes and datatype predicates.
• WSML-DL is the Description Logic variant of WSML. It captures the Descrip-
tion Logic S H I Q(D), which corresponds to a large part of (the DL species
of) OWL [10]. This variant allows for interoperability with OWL DL ontologies:
WSML-DL ontologies, goals, and Web services may import OWL DL ontologies.
• WSML-Flight is the least expressive of the two LP-based variants of WSML.
Compared to WSML-Core, it adds features such as meta-modeling, constraints,
and nonmonotonic negation. WSML-Flight is based on a Logic Programming
variant of F-Logic [20] and is semantically equivalent to Datalog with inequality
and (locally) stratiﬁed negation [28]. This variant allows for interoperability with
RDF graphs and RDFS ontologies: WSML-Flight ontologies, goals, and Web
services may import RDF graphs and RDFS ontologies.

• WSML-Rule extends WSML-Flight with further features from Logic Program-
ming, namely the use of function symbols, unsafe rules, and unstratiﬁed negation,
in order to increase the language expressibly.

• WSML-Full uniﬁes WSML-DL and WSML-Rule. A deﬁnition of the semantics
for WSML-Full, generalizing WSML-DL and WSML-Rule, is proposed in [6, 7].
However, as the combination of Description Logics and nonmonotonic logic pro-
grams is still an open research issue—some work has been done on the topic
[4, 5, 8, 12, 24, 25, 30], but there is no consensus on which is the most appro-
priate semantics for the combination. Therefore, the current version of WSML
does not deﬁne a semantics for WSML-Full, but instead outlines a number of
properties the semantics should exhibit.
WSML has two alternative layering paths: WSML-Core ⇒ WSML-DL ⇒
WSML-Full and WSML-Core ⇒ WSML-Flight ⇒ WSML-Rule ⇒ WSML-Full.
For both layering paths, WSML-Core and WSML-Full mark the least and most ex-
pressive layers. The two layering paths are to a certain extent disjoint, namely the
inter-operation between WSML-DL, on the one hand, and WSML-Flight and -Rule,
on the other, is only possible through a common subset (WSML-Core) or through
a very expressive superset (WSML-Full). More details on WSML layerings can be
found in [9].

In the next sections, we provide an overview of the WSML language through
an introduction of its syntax and vocabulary. In particular, we discuss WSML by
presenting its user friendly syntax, that presents WSML in terms of a normative
surface syntax with keywords based on WSMO. A detailed discussion of the other
syntaxes of WSML, namely XML and RDF, is presented in [9].

136

8 The Web Service Modeling Language

8.2.2 WSML Basis

As already introduced, WSML aims at modeling both conceptual elements and re-
lated logical rules. To provide proper support for both modeling aspects, the WSML
syntax is composed by two parts: the conceptual syntax and the logical expression
syntax.

The conceptual syntax reﬂects the WSMO conceptual model and it is indepen-
dent from the particular WSML variant. The WSML conceptual syntax is shared be-
tween all variants, with the exception of some restrictions that apply to the modeling
of ontologies in WSML-Core and WSML-DL. It allows for the modeling of ontolo-
gies, Web services, goals and mediators. The logical expression syntax provides
access to the full expressive power of the language underlying the particular vari-
ant. The basic entry points for logical expressions in the conceptual syntax are the
axioms in ontologies, the assumptions, preconditions, postconditions, and effects in
capability descriptions, and the transition rules in choreography descriptions.

WSML is a “Web language” and according to this design principle adopts Web
standards in its syntax. In particular, aside from including an XML and RDF syn-
tax, WSML adopts IRIs [11] for the identiﬁcation of objects and resources, uses
the XML schema datatypes [2] for typing concrete data values, and reuses the
XQuery [16] comparators and functions for corresponding built-in predicates.

8.2.2.1 IRIs and WSML

WSML distinguishes between three types of identiﬁers: IRIs, compact IRIs (i.e.,
IRIs based on namespaces) and data values. Compact IRIs are speciﬁc to the surface
syntax, and do not appear in the XML and RDF serialization.

An IRI (Internationalized Resource Identiﬁer) [11] uniquely identiﬁes a re-
source (e.g., concepts, relations, individual) in a Web-compliant way. IRI is a stan-
dard, evolution of the popular URI standard, and constitutes one of the building
blocks of the Web architecture [18]. In the surface syntax IRIs are delimited us-
ing an underscore and double quote ‘_"’, and a double quote ‘"’, for example,
_"http://www.wsmo.org/wsml/wsml-syntax#".

An IRI can be abbreviated to a compact IRI, which is of the form pre-
ﬁx#localname to improve readability. In case the preﬁx and separator ‘preﬁx#’ are
omitted, the name belongs to the default namespace. Both the namespace preﬁxes
and the default namespace are speciﬁed in the prologue of a WSML document (see
Listing 8.1 for an example). The header also includes the deﬁnition of the WSML
ﬂavor adopted by the WSML document.

A WSML compact IRI corresponds to the use of Qualiﬁed Names (QNames) in
RDF which is slightly different from QNames in XML. While in XML a QName is
merely an abbreviation for an IRI, in RDF and WSML it is a tuple <namespaceURI,
localname>.

WSML enables the use of anonymous identiﬁers. An anonymous identiﬁer rep-
resents an IRI which is meant to be globally unique. Unnumbered anonymous IDs

8.2 Technical Solution

137

are denoted with ‘_#’ and each occurrence denotes a new anonymous ID. Different
occurrences of ‘_#’ are unrelated. Numbered anonymous IDs are denoted with ‘_#n’
where n stands for an integer denoting the number of the anonymous ID. Anony-
mous identiﬁers are disallowed for the following elements: the top-level elements
ontology, goal, webService, mediator, capability, interface, choreography and or-
chestration.

8.2.2.2 WSML Datatypes

Datatypes in WSML are inherited from XML. They include strings, integers, dec-
imals, or structured datatypes (e.g., dates and XML content). Strings are Uni-
code character sequences delimited with double quotes (e.g., "Dieter Fensel"), where
quotes are escaped using the backslash character ‘\’; integers are sequences of dig-
its, optionally preceded with the minus symbol (e.g., –31 0 5 1889); decimals consist
of two sequences of digits separated with a point, optionally preceded with the mi-
nus symbol (e.g., –42.34 –1.47 537.341 8768.1).

To represent structured data values using strings, integers, and decimals, WSML
deﬁnes constructor functions, called datatype wrappers; the names of these wrap-
pers correspond to the IRIs of the corresponding (XML schema) datatypes. For
example, the date “March 30th, 2009” is represented as: xsd#date(2009,3,30). In
WSML, datatypes can be instanciated by using the syntax shortcut _ in front of
the datatype name (e.g., _date(2009,3,30)).

Strings, integers, and decimals correspond to values of the respective XML
schema datatypes [2] string, integer, and decimal. Furthermore, the datatypes rec-
ommended for use in WSML are the XML schema datatypes, plus the RDF datatype
rdf#XMLLiteral.

8.2.2.3 WSML Prologue

Each WSML document contains a section with all the common elements between
the different variants and different speciﬁcations. In particular, the prologue speci-
ﬁes the WSML variant adopted by the document (e.g., Flight, DL) and the names-
pace deﬁnitions for the document. Variants are speciﬁed with the keyword wsmlVari-
ant, while namespaces are speciﬁed with the keyword namespace. The following
listing presents a WSML prologue:

wsmlVariant _"http://www.wsmo.org/wsml/wsml−syntax/wsml−ﬂight"
namespace { _"http://example.org/ontologies/Weather#",
loc _"http://example.org/ontology/Location#",
dc _"http://purl .org/dc/elements/1.1/",
xsd _"http://www.w3.org/2001/XMLSchema#",
wsml _"http://www.wsmo.org/wsml/wsml−syntax#" }

In the listing, the WSML variant adopted is WSML-Flight, Table 8.1 reports all

the IRIs for the different variants.

The namespace without Qualiﬁed Name constitutes the default namespace of the

document.

138

8 The Web Service Modeling Language

Table 8.1 IRIs for the different WSML variants

WSML Variant

IRI

WSML-Core

WSML-Flight

WSML-Rule

WSML-DL

WSML-Full

8.2.2.4 WSML Header

http://www.wsmo.org/wsml/wsml-syntax/wsml-core

http://www.wsmo.org/wsml/wsml-syntax/wsml-ﬂight

http://www.wsmo.org/wsml/wsml-syntax/wsml-rule

http://www.wsmo.org/wsml/wsml-syntax/wsml-dl

http://www.wsmo.org/wsml/wsml-syntax/wsml-full

The WSML Header consists of the common parts among any WSML speciﬁcation.
All WSML speciﬁcations have in common the possibility of having annotations to
provide metadata about them, ontology imports to refer to ontologies deﬁned in
other WSML descriptions (or other Semantic Web based languages, e.g., OWL and
RDF Schema), use mediators in order to enable interoperability with other WSML
speciﬁcations.

Annotations Annotations are used to describe metadata such as natural language
names for WSML elements, data about the authors, and more elaborate natural lan-
guage descriptions. An annotation consists of a property–value pair, and multiple
annotations are grouped into annotation blocks which start with the keyword anno-
tations and end with the keyword endAnnotations. Such annotation blocks always
occur immediately after the deﬁnition of an element (e.g., Web service, ontology,
concept, axiom) and the annotations in the block apply to the identiﬁer of the ele-
ment.

Consider the following description:

webService _"http://example.org/services/Weather"

annotations

dc#creator hasValue "Federico M. Facca"
dc#description hasValue "Describes an web service for the weather forecast"
wsml#version hasValue "1.2"
dc#title hasValue "Weather Service"
dc#date hasValue _date(2009,3,30)
dc#format hasValue "text/plain"
dc#language hasValue "en−US"

endAnnotations

It is the description of a Web service that is identiﬁed by the IRI http://example.
org/services//Weather. The description contains several annotations, namely a cre-
ator, a description, a version, a title, a date, a format, and a language. For annota-
tions, WSML recommends the adoption of Dublin Core properties [34] (e.g., title,
creator). Other properties can also be adopted, for example, WSML deﬁnes a version
property to identify the version of a document.

Import Ontologies Any WSMO element may import ontologies in order to
reuse the terminologies in the corresponding descriptions. The ontology imports in

8.2 Technical Solution

139

WSML are declared using the importsOntology keyword, followed by a list of IRIs
identifying the ontologies to be imported. The imported ontologies may be WSML,
RDF Schema, or OWL DL ontologies.

The following listing shows how an ontology about locations can be imported in

the weather forecast Web service.

webService _"http://example.org/services/Weather"

importsOntology {_"http://example.org/ontology/Location"}

Import Mediators Mediators ensure interoperability between different WSML
elements (ontologies, goal, Web services). A mediator can be imported in a WSML
element by using the keyword usesMediator. The types of mediators which can be
used are constrained by the type of speciﬁcation. An ontology allows for the use of
different mediators than, for example, a goal or a Web service (see Sect. 8.2.6 for
more details).

The following listing shows how an ontology about weather can use an ontology

to ontology mediator to resolve issues on measurement units heterogeneity.

webService _"http://example.org/ontology/Weather"

usesMediator _"http://example.org/ooMetricUnitsToImperialUnits"

8.2.3 Ontologies in WSML

An ontology in WSML consists of the elements concept, relation, instance, rela-
tionInstance and axiom. Additionally, an ontology may have annotations and may
import other ontologies. We start the description of WSML ontologies with an ex-
ample which demonstrates the elements of an ontology, in Listing 8.1, and describe
the individual elements in more detail below.

The prologue of the listing illustrates how the WSML variant is declared and how

the default namespace and namespace preﬁxes are declared.

In the following section, we discuss the elements that compose an ontology in

WSML in more detail.

8.2.3.1 Concepts

Concepts (sometimes also known as ‘classes’) play a central role in ontologies: they
form the basic terminology of the domain of discourse. A concept is described by
the attributes associated with it. The annotations, as well as the attribute deﬁnitions,
are grouped together in one syntactical construction, as can be seen in the example
concept WeatherObservation in Listing 8.1.

Attribute deﬁnitions can take two forms, namely constraining (using ofType) and
inferring (using impliesType) attribute deﬁnitions. Constraining attribute deﬁnitions

140

8 The Web Service Modeling Language

(cid:3)

(cid:2)
wsmlVariant _"http://www.wsmo.org/wsml/wsml−syntax/wsml−ﬂight"
namespace { _"http://example.org/ontology/Weather#",

loc _"http://example.org/ontology/Location#",
dc _"http://purl .org/dc/elements/1.1/",

units _"http://example.org/ontology/MetricUnits#"

}

ontology _"http://example.org/ontology/Weather"
importsOntology {

_"http://example.org/ontology/Location",
_"http://example.org/ontology/MetricUnits"

}

concept WeatherObservation

annotations

dc#description hasValue "This concept describes weather observations"

endAnnotations
hasLocation ofType (1 1) loc#Location
hasTime impliesType (1 1) _dateTime
hasTemperature ofType (1 1) TemperatureObservation
hasWind ofType (1 1) WindObservation
hasPressure ofType (1 1) PressureObservation
hasCloud ofType (0 ∗) CloudObservation
hasPrecipitation ofType (0 1) PrecipitationObservation

concept Observation

concept TemperatureObservation subConceptOf Observation

hasMeasure ofType (1 1) _decimal
hasUnit impliesType (0 1) units#TemperatureUnit

concept WindObservation subConceptOf Observation

hasMeasure ofType (1 1) _decimal
hasUnit impliesType (0 1) units#SpeedUnit
hasDirection ofType (1 1) _decimal

concept PressureObservation subConceptOf Observation

hasMeasure ofType (1 1) _decimal
hasUnit impliesType (0 1) units#SpeedUnit

concept CloudObservation subConceptOf Observation

hasType impliesType (1 1) CloudType
hasAmount ofType (1 1) _decimal
hasHeight ofType (1 1) _decimal

concept CloudType

concept PrecipitationObservation subConceptOf Observation

instance WeatherObservationExample memberOf WeatherObservation

hasLocation hasValue loc#Innsbruck
hasTime hasValue _dateTime(2009,3,30,10,20,0.000)
hasTemperature hasValue TemperatureObservationExample
hasWind hasValue WindObservationExample
hasPressure hasValue PressureObservationExample

instance TemperatureObservationExample memberOf TemperatureObservation

hasMeasure hasValue _decimal(14.0)
hasUnit hasValue units#Celsius

instance WindObservationExample memberOf WindObservation

hasMeasure hasValue _decimal(14.0)
hasUnit hasValue units#Knots
hasDirection hasValue _decimal(30.0)

instance PressureObservationExample memberOf PressureObservation
(cid:4)

hasMeasure hasValue _decimal(1020.0)

(cid:5)

Listing 8.1 An example WSML ontology

8.2 Technical Solution

141

deﬁnes a typing constraint on the values for this attribute, similar to integrity con-
straints in databases; inferring attribute deﬁnitions implies that the type of the values
for the attribute is inferred from the attribute deﬁnition, similar to range restrictions
on properties in RDFS and universal value restrictions in OWL.1

It is possible to declare several types for a single attribute; these are interpreted
conjunctively which means that every type is applicable. If the type of the attribute
is unknown, the list maybe empty. Each attribute deﬁnition may have a number of
associated features, namely, transitivity, symmetry, reﬂexivity, and the inverse of an
attribute, as well as minimal and maximal cardinality constraints.

Constraining attribute deﬁnitions, as well as cardinality constraints, require
closed-world reasoning and are thus not allowed in WSML-Core and WSML-DL.
As opposed to features of roles in Description Logics, attribute features such as tran-
sitivity, symmetry, reﬂexivity and inverse attributes are local to a concept in WSML.
Thus, none of these features may be used in WSML-Core and WSML-DL.

8.2.3.2 Relations

Different WSML variants offer a different level of support for modeling relations.
As such, WSML-Core and WSML-DL do not allow using relations; however, unary
and binary relations in Description Logics correspond to concepts and attributes
in WSML. Relations may be organized in a hierarchy using subRelationOf and the
parameters may be typed using parameter type deﬁnitions of the form (ofType type)
and (impliesType type), where type is a concept identiﬁer or a (possibly empty) list of
concept identiﬁers. The usage of ofType and impliesType correspond with the usage
in attribute deﬁnitions. Namely, parameter deﬁnitions with the ofType keyword are
used to check the type of parameter values, whereas parameter deﬁnitions with the
impliesType keyword are used to infer concept membership of parameter values.

The following is an example of a relation.

relation hasTemperatureObserviation(ofType loc#Location, ofType _decimal, ofType _dateTime)

annotations

dc#description hasValue "Relation between Location, Temperature and time of observation."

endAnnotations

8.2.3.3 Instances

An instance may be member of zero or more concepts and may have a number of
attribute values associated with it. Note that the speciﬁcation of concept membership
is optional and the attributes used in the instance speciﬁcation do not necessarily
have to occur in the associated concept deﬁnition. Consequently, WSML instances

1The distinction between inferring and constraining attribute deﬁnitions is explained in more detail
in [3, Sect. 2].

142

8 The Web Service Modeling Language

can be used to represent semi-structured data, since without concept membership
and constraints on the use of attributes, instances form a directed labeled graph.
Because of the possibility to capture semi-structured data, most RDF graphs can be
represented as WSML instance data, and vice versa.

8.2.3.4 Axioms

Axioms provide a means to add arbitrary logical expressions to an ontology. Such
logical expressions can be used to reﬁne concept or relation deﬁnitions in the on-
tology, but also to add arbitrary axiomatic domain knowledge and to express con-
straints. The following is an example of an axiom that deﬁnes the relation hasTem-
peratureObservation (indicating the temperature measurement at a certain point in
time at a given location) as part of the domain knowledge of the ontology presented
in Listing 8.1.

axiom hasTemperatureObserviationAxiom

annotations

dc#relation hasValue hasTemperatureObserviation
dc#description hasValue "Deﬁnes the hasTemperatureObserviation relation as the relation between location

and the temperatures observed at that location."

endAnnotations
deﬁnedBy

hasTemperatureObservation(?x,?y,?z) :− ?k memberOf WeatherObservation
and ?k[hasLocation hasValue ?x, hasTime hasValue ?z, hasTemperature hasValue ?w]
and ?w[hasMeasure hasValue ?y].

The syntax of logical expressions is explained in more detail in the next subsection.

8.2.3.5 Logical Expressions

WSML logical expressions are used in axioms of ontologies and in Web service
capabilities, as well as in transition rules of Web service choreographies and non-
functional properties. In this section, we ﬁrst explain the general logical expression
syntax, which encompasses all WSML variants, and then review the restrictions on
this general syntax for each of the variants.

WSML logical expression syntax adopts a ﬁrst-order logic style: it has constants,
function symbols, variables, predicates and a set of logical connectives (i.e., nega-
tion, disjunction, conjunction, implication, and quantiﬁers). WSML also includes
a number of connectives speciﬁcally for the Logic Programming based variants
(i.e., negation-as-failure, LP-implication and database-style integrity constraints).
Finally, all the keywords deﬁned to model ontologies (e.g., memberOf, subCon-
ceptOf, . . . ) can be used to create a logical expression.

Logical expressions may include variables as well. In WSML, variables are iden-
tiﬁed by a question mark, followed by an arbitrary number of alphanumeric charac-
ters, e.g., ?x, ?name, ?123. Free variables in WSML (i.e., variables that are not ex-
plicitly quantiﬁed) are implicitly universally quantiﬁed outside of the formula (i.e.,
the logical expression in which the variable occurs is the scope of quantiﬁcation).

8.2 Technical Solution

143

Exceptions to this rule are: variables included in the sharedVariables construct and
variables included in a logical expression occurring in a non-functional property
where they act as parameters.

Terms are either identiﬁers (i.e., IRIs or data values), variables, or constructed
terms of the form f(t1, . . . , tn). An atom is a predicate symbol with a number of terms
as arguments, e.g., p(t1, . . . , tn). In addition, WSML has a special kind of atoms,
called molecules, which are used to capture information about concepts, instances,
attributes and attribute values. WSML molecules are:
• An isa molecule is a concept membership molecule of the form t1 memberOf t2 or
a subconcept molecule of the form t1 subConceptOf t2, where t1 and t2 are terms.
• An object molecule is an attribute value expressions t1[t2 hasValue t3], a con-
straining attribute signature expression t1[t2 ofType t3], or an inferring attribute
signature expression t1[t2 ofType t3], where t1, t2, and t3 are terms.

WSML ﬁrst-order connectives include:

• The unary negation operator neg.
• The binary operators for conjunction and.
• Disjunction or.
• Right implication implies.
• Left implication impliedBy.
• Dual implication equivalent.

Variables may be universally quantiﬁed using forall or existentially quantiﬁed
using exists. First-order formulae are obtained by combining atoms using the men-
tioned connectives. Examples of ﬁrst-order formulae in WSML are [15]:

//everypersonhasafather
forall ?x (?x memberOf Person implies exists ?y (?x[father hasValue ?y])).
//ManandWomanaredisjoint.
?x memberOf Man implies neg ?x memberOf Woman

Logic Programming based WSML variants include: the negation-as-failure sym-
bol naf in front of atomic formulas, the special logic programming implication sym-
bol :-, and the integrity constraint symbol !-. A Logic Programming rule consists
of a head and a body, separated by the :- symbol. An integrity constraint consists
of the symbol !- followed by a rule body. Negation-as-failure naf is only allowed
to occur in the body of a Logic Programming rule or an integrity constraint. The
following logical connectives are allowed in the head of a Logic Programming rule:
and, implies, impliedBy, and equivalent. The following connectives are allowed in the
body of a rule (or constraint): and, or, and naf. The logical expressions previously
expressed in ﬁrst-order formulae can be also represented with LP rules and database
constraints [15]:

//everypersonhasafather
?x[father hasValue f(?y)] :− ?x memberOf Person.
//ManandWomanaredisjoint
!− ?x memberOf Man and ?x memberOf Woman.

144

Table 8.2 Features in
WSML variants

8 The Web Service Modeling Language

Feature

Core DL

Flight

Rule

Full

Classical Negation (neg)

Existential Quantiﬁcation

(Head) Disjunction

n-ary relations

Meta Modeling

Default Negation (naf)

LP implication

Integrity Constraints

Function Symbols

Unsafe Rules

–

–

–

–

–

–

–

–

–

–

X

X

X

–

–

–

–

–

–

–

–

–

–

X

X

X

X

X

–

–

–

–

–

X

X

X

X

X

X

X

X

X

X

X

X

X

X

X

X

X

In the previous paragraphs, we discussed the general syntax of WSML logical
expressions. Each variant poses some restriction on the use of speciﬁc connectives
and on the usage of modeling constructs.

• WSML-Core corresponds with the intersection of Description Logic and Horn
Logic. WSML-Core disallows the use of the equality symbol, disjunction in the
head of a rule and existentially quantiﬁed variables in the head of a rule. As a DL
fragment, it disallows the use of function symbols, restricts the arity of predicates
to unary and binary, and prohibits chaining variables over predicates.

• WSML-DL relaxes WSML-Core constraints toward complete support of DL
S H I Q. WSML-DL does not allow the use of function symbols, restricts the
arity of predicates to unary and binary, and prohibits chaining variables over pred-
icates. WSML-DL allows classical negation, and disjunction and existential quan-
tiﬁcation in the heads of implications.

• WSML-Flight extends WSML-Core toward Horn Logic. WSML-Flight allows
variables in place of instance, concept and attribute identiﬁers, relations of arbi-
trary arity. Finally, the body of a WSML-Flight rule allows conjunction, disjunc-
tion and default negation. The head and body are separated by the LP implication
symbol.

• WSML-Rule extends WSML-Flight with function symbols and unsafe rules.
• WSML-Full is equivalent to the general logical expression syntax of WSML and
allows the full expressiveness of all other WSML variants as conjunction of the
expressive power of Description Logic and Horn Logic. In particular, WSML-
Full adds to WSML-DL full ﬁrst-order modeling: n-ary predicates, function sym-
bols and chaining variables over predicates. Furthermore, WSML-Full adds to
WSML-DL non-monotonic negation. With respect to the WSML-Rule variant,
WSML-Full adds disjunction, classical negation, multiple model semantics, and
the equality operator.

Table 8.2 mentions a number of language features and indicates in which variant

the feature may be used, illustrating the differences between each variant.

8.2 Technical Solution

(cid:2)
wsmlVariant _"http://www.wsmo.org/wsml/wsml−syntax/wsml−ﬂight"

namespace { namespace { _"http://example.org/ontologies/Weather#",

loc _"http://example.org/ontology/Location#",
dc _"http://purl .org/dc/elements/1.1/",
wsml _"http://www.wsmo.org/wsml/wsml−syntax#",
xsd _"http://www.w3.org/2001/XMLSchema#"

}

webService _"http://example.org/service/WeatherUSA"

annotations

dc#creator hasValue "Federico M. Facca"
dc#description hasValue "Describes an web service for the weather forecast"
wsml#version hasValue "1.2"
dc#title hasValue "Weather Service"
dc#date hasValue _date(2009,3,30)
dc#format hasValue "text/plain"
dc#language hasValue "en−US"

endAnnotations

importsOntology {

_"http://example.org/ontology/Location",
_"http://example.org/ontology/Weather"

}

capability

...

interface

...

nonFunctionalProperty

...(cid:4)

Listing 8.2 An example Web service description

8.2.4 Web Services in WSML

145
(cid:3)

(cid:5)

WSML based Web service descriptions formalize the functionality, behavior, and
other aspects of Web services. A Web service description consists of a capabil-
ity, which describes the functionality, one or more interfaces, which describe the
possible ways of interacting with the service, and non-functional properties, which
describe non-functional aspects of the service. Listing 8.2 shows the structure of a
simple Web service for weather forecasts.

8.2.4.1 Capabilities

Capabilities deﬁne functionality provided by services and restrictions over them. In
WSML, capabilities can be formalized in two ways: (i) as concepts of a task ontol-
ogy and (ii) as a detailed state-based description of the functionality. Capabilities of
the type (i) are also referred to as set-based capabilities; capabilities of the type (ii)
are also referred to as state-based capabilities.

A set-based capability simply consists of the capability keyword followed by an
IRI identifying a concept in a task ontology. Such a task ontology is typically im-

146

(cid:2)

capability

sharedVariables {?location}
precondition
annotations

8 The Web Service Modeling Language
(cid:3)

dc#description hasValue "The input is of a location and it must be in the US."

endAnnotations
deﬁnedBy

?location [hasCountry hasValue loc#US] memberOf loc#Location.

postcondition
annotations

dc#description hasValue "The weather forecast returned corresponds to the input location. "

endAnnotations
deﬁnedBy
?forecast[hasLocation hasValue ?location] memberOf WeatherForecast.

(cid:4)

(cid:5)

Listing 8.3 An example of service capability

ported in the Web service to which the capability belongs. In the case of the Web
service for weather forecasts, a set-based capability can be:

(cid:2)
webService _"http://example.org/service/WeatherUSA"

importsOntology {

_"http://example.org/ontology/Location",

_"http://example.org/ontology/Weather"

}

capability _"http://example.org/ontology/WeatherTasks#ProvideWeatherForecast"

(cid:4)

(cid:3)

(cid:5)

A state-based capability consists of a set of axioms deﬁning four different types
of capabilities: preconditions, assumptions, postconditions and effects. Precondi-
tions and assumptions describe the state before the execution of a Web service.
While preconditions describe conditions over the information space—that is, con-
ditions over the input, e.g., the location given as input is in the US—assumptions
describe conditions over the state of world that cannot be veriﬁed by the requester
of the service, but which might explain the failure of the service, e.g., there must
exist a weather forecast for the given location. Postconditions describe the relation
between the input and the output, e.g., the weather forecast returned corresponds to
the input location. In this sense, they describe the information state after execution
of the service. Effects describe changes caused by the service beyond the inputs
and outputs, e.g., the user credit is reduced by the amount of the cost of the service
invocation.

Listing 8.3 describes the capability of the simple Web service for adding items
to a shopping cart: given a shopping cart identiﬁer and a number of items, the items
are added to the shopping cart with this identiﬁer. The sharedVariables construct is
used to identify variables that are shared between the pre- and postconditions and
between the assumptions and effects. Shared variables can be used for to refer to
the input (?cartId and ?item) or pass variables between the pre- and postcondition or
assumption and effect (e.g., ?number).

8.2 Technical Solution

147

8.2.4.2 Interfaces and Choreographies

Interfaces describe how to interact with a service from the requester point-of-
view (choreography) and how the service interacts with other services and goals
it needs to fulﬁll its capability (orchestration). Orchestration descriptions are exter-
nal to WSML; WSML allows referring to any orchestration description identiﬁed
by an IRI.

WSML provides a language for describing choreographies, called the WSML
choreography language. It is also possible to refer to any choreography that has
an IRI. However, WSML does not prescribe how such a choreography should be
interpreted.

A choreography description is a model for possible conversations—that is, se-
quences of message exchanges—between the service requester and the service
provider. Patterns of message exchanges are governed by transition rules; given the
current state, the transition rules determine the next step in the conversation. The
messages themselves consist of ontology instance information, and the background
knowledge contained in ontologies is taken into account when evaluating the tran-
sition rules.

A central notion in WSML choreographies is the state of a conversation. Tech-
nically, a state consists of instance data of some ontology speciﬁc to a certain point
during the service execution. State transitions correspond to update, insertion, or
deletion of instance data. Communication between the requester and provider is
modeled by marking certain ontology concepts as in or out concepts; an incoming
message (from the requester to the provider) results in the insertion of an instance
of an in concept; inserting an instance of an out concept results in a message being
sent from the provider to the requester.

A single conversation corresponds to a choreography run, which consists of a
start state, a sequence of intermediate states, and an end state. State transitions are
governed by the transition rules; ﬁring of a rule corresponds to a state transition.
Such a state transition may or may not correspond to a message exchange between
the requester and provider.

Listing 8.4 shows an example of an interface description with a choreography.
A choreography is deﬁned by a state signature and a set of rules. The state sig-
nature deﬁnes the state ontology over which the rules are evaluated and updates
performed. In addition, the state signature assigns modes to ontology concepts and
relations. These modes determine the role that a particular concept/relation plays in
the choreography, as well as the relationship between instances of such a concep-
t/relation and message formats, deﬁned using, for example, WSDL.

Following the state signature block are the transition rules which express con-
ditions that are evaluated with respect to the state and the background ontologies.
If the condition of a transition rule holds in this state, the rule is ﬁred. If a transi-
tion rule ﬁres, the enclosed update rules change the state by adding, deleting, or
updating instances.

The WSML choreography language is very general, and can be used in a number
of different ways. For example, there is no explicit control ﬂow between the transi-
tion rules—that is, the order of rule ﬁring is not determined by the order the rules

148

(cid:2)
interface WeatherUSAInterface

annotations

8 The Web Service Modeling Language
(cid:3)

dc#title hasValue "WeatherUSA Choreography"
dc#description hasValue "An example of a choreography for retrieving weather forecast"

endAnnotations

choreography WeatherUSAInterfaceChoreography

stateSignature WeatherUSAInterfaceSignature

importsOntology _"http://example.org/ontology/Weather"

in

wea#WeatherQuery withGrounding
_"http://example.org/webservices/USWeatherForecast/Weather#wsdl.interfaceMessageReference(

WeatherServicePortType/GetWeatherForCityState/In)",

out

wea#WeatherForecast withGrounding
_"http://example.org/webservices/USWeatherForecast/Weather#wsdl.interfaceMessageReference(

WeatherServicePortType/GetWeatherForCityState/Out)",

transitionRules WeatherUSAInterfaceTransitions

forall ?search

with

(?search[

hasCity hasValue ?city,
hasState hasValue ?state

] memberOf wea#WeatherQuery
and exists{?location} (

?location memberOf loc#Location and
?location [hasCity hasValue ?city, hasState hasValue ?state]

)

)

do

add(?forecast[

hasLocation hasValue ?location
] memberOf wea#WeatherForecast

)
delete(?search memberOf wea#WeatherQuery)

(cid:4)

endForall

Listing 8.4 An example interface declaration

(cid:5)

are written, but rather by the conditions (current state) at the time of the execution.
It is certainly possible to add control ﬂow to the transition rules, for example, by
deﬁning a controlled concept that mimics an explicit state using an integer.

8.2.4.3 Non-Functional Properties

Non-functional properties of a service are not concerned with aspects of the service
directly related to functionality, but that are nonetheless of interest to the requester.
Examples of non-functional properties are: provider of the service, cost of service
invocation, availability, and security [26].

Non-functional properties should not be confused with annotations: whereas an-
notations are concerned with the description of the service, e.g., creator of the

8.2 Technical Solution

(cid:2)

nonFunctionalProperty

prop#accuracy hasValue prop#highAccuracy
annotations

dc#description hasValue "The accuracy of the data returned by the service is high."

149
(cid:3)

endAnnotations

nonFunctionalProperty

prop#price hasValue ?price
annotations

dc#description hasValue "The price for service invocation is determined by the relation servicePrice,

which is deﬁned in the service properties ontology."

endAnnotations
deﬁnedBy

(cid:4)

exists ?x(?x memberOf prop#ServiceRequester and servicePrice(?x, ?price).

(cid:5)

Listing 8.5 Example non-functional properties

description, natural language description, non-functional properties are concerned
with the service itself.

As the name indicates, non-functional properties are properties, and are thus es-
sentially name–value pairs. However, in contrast to annotations, it is possible to say
more about non-functional properties using logical expressions. Consequently, there
are three kinds of non-functional properties: (i) simple name–value pairs, (ii) con-
ditional name–value pairs which should only be considered if the given logical ex-
pression is true (i.e., follows from the ontology), and (iii) open name–value pairs
where a given logical expression determines the value(s) of the property [32]. List-
ing 8.5 shows examples of all three kinds of non-functional properties, all related to
the service description in Listing 8.2.

8.2.5 Goals in WSML

Goal represents the requester’s view over the desired functionality of a service.
Thus, goals are described in a symmetric way with respect to Web service descrip-
tions. Therefore, goal descriptions comprise the same modeling elements as Web
service descriptions, namely a capability, one or more interfaces, and non-functional
properties. Whereas services are described from the provider’s point of view, goals
are described from the requester’s point of view.

In an ideal world, requesters and providers would use the same domain ontolo-
gies for the description of their goals and Web services, respectively. However,
this cannot be assumed in an open environment. A requester might ﬁnd it more
convenient to use his own terminology rather than the terminology of the service
providers; furthermore, different providers may use different terminologies to de-
scribe the same functionality. In general, it cannot be assumed that the requester is
aware of the terminologies used by all the service providers with which it interacts.
In case there is a mismatch between the terminologies used in a goal and a Web
service, mapping or mediation is required during discovery, selection, as well as us-
age of the service. To mediate between the requester and provider ontologies during

8 The Web Service Modeling Language
(cid:3)

150

(cid:2)
goal _"http://example.org/service/WeatherInnsbruck"

importsOntology {

_"http://example.org/ontology/Location",

_"http://example.org/ontology/Weather"

}

capability

postcondition
annotations

dc#description hasValue "I want to know the weather forecast for Innsbruck."

endAnnotations
deﬁnedBy
?forecast[hasLocation hasValue loc#Innsbruck] memberOf WeatherForecast.

(cid:4)

(cid:5)

Listing 8.6 Example goal

discovery, it is necessary to be aware of the mappings between the ontologies (e.g.,
[27, 31]).

WSML does not prescribe how a discovery engine should specify or use ontology
mappings. There are, however, a number of ways in which such mappings can be
made explicit in WSML. A wgMediator speciﬁes a link between a goal and a Web
service. Such a mediator can import an ontology that contains mappings between the
ontologies used in the goal and Web service descriptions. WSML does not prescribe
how such a mediator should be used, or how the mappings in the imported ontology
should be processed.

In case a requester or provider knows about ontologies that are used in potentially
matching Web services or goals, the mappings can be imported in the goal or Web
service directly using the importsOntology directive. Mappings that are imported in
this way are added as mapping rules to the ontologies that are used for the goal or
Web service speciﬁcation [23]. Listing 8.6 shows an example of a goal represented
in WSML.

8.2.5.1 Capability

On the level of a set-based capability description, there is not much difference be-
tween the requester’s and provider’s point of view—they both specify the capability
of the requested or provided service. In a state-based capability description, how-
ever, the requester and provider will have different objectives in their descriptions
of the preconditions, postconditions, assumptions, and effects.

Preconditions The service provider will want to make sure that all information re-
quired to execute the service is present when the service is executed. Therefore, he
has an interest in describing the preconditions of the service in detail. The requester,
on the other hand, may want to disclose some of his (personal) information, but
most likely not all of it. Furthermore, if requesters were to include all their informa-
tion in the preconditions of every goal, the task of writing the goal would become
unmanageable, and even more so the processing of that goal. Therefore, we may
assume that the requester might include some of his information in the precondi-
tion, but it will in no way be complete. This has implications for possible discovery

8.2 Technical Solution

151

mechanisms: even if a Web service provides the exact requested functionality, it
cannot be assumed in general that the preconditions of a goal will exactly match the
preconditions of the service.

Assumptions With respect to assumptions, neither the requester nor the provider
can provide complete descriptions. There are many things that must hold in the real
world to ensure that the service can be executed successfully, e.g., a delivery address
must exist, the company providing the service must not go bankrupt, and war must
not break out. While a provider may want to model the assumption that the provided
delivery address must exist in the real world in order to deliver a product, he will
not be poised to model aspects related to bankruptcy and war. Considerations for the
requester are similar: the requester can guarantee a number of things to hold, but an
exhaustive list (e.g., including guarantees that his house does not have a leaky roof
and his car will have enough gas to drive to the supermarket) would become too long
for any practical use. In general, it may be expected that the provider will include
some assumptions that are directly related to the provided service (e.g., for payment,
the limit of the credit card must not have been reached) that might help a potential
requester to determine whether the service is suitable and to explain possible failures
in execution of the service, but the description will not be exhaustive.

From the above description, it may seem that the prospect of using state-based
capabilities for automated matching is rather bleak when looking at our expecta-
tions concerning the description of preconditions and assumptions, especially from
the side of the requester; if the formal descriptions are not detailed enough, or even
missing, automated matching is not possible. Fortunately, the situation looks a bit
better when considering postconditions and effects. There are two reasons for this:
ﬁrst, postconditions and effects are only concerned with the desired and actual out-
puts and real-world effects of the service; and secondly therefore, requesters have an
interest in including detailed descriptions of the postconditions and effects in their
goals.

Postconditions and Effects The requester’s main interest during a service invo-
cation (or even prior to the invocation) is what the service actually “does” for him.
If he is interested in speciﬁc information (e.g., product availability) that should be
an output of the service, he will describe the postconditions concerning this infor-
mation. If he is interested in certain real-world effects (e.g., product delivery), he
will describe the corresponding effects. The provider may ﬁnd it more important to
ensure that all preconditions and assumptions are met before executing the service,
rather than describing the output and effects in detail; however, if the provider wants
the service to be found, he will have to describe the postconditions and effects in
sufﬁcient detail.

8.2.5.2 Interfaces and Choreographies

Considerations for interfaces are similar to those for preconditions. There is typi-
cally a ﬁxed way (or number of ways) in which a service can interact with a re-
quester. The service provider has an interest in accurately describing this interface

152

(cid:2)
ooMediator _"http://example.org/ooMediatorUSUnitsToMetricUnits"

8 The Web Service Modeling Language
(cid:3)

annotations

dc#description hasValue "This ooMediator transform units expressed
in the US Measure System to the Metric Measure System."

endAnnotations
source _"http://example.org/ontology/USUnits"
target _"http://example.org/ontology/MetricUnits"

(cid:4)

Listing 8.7 Example mediator

(cid:5)

so that potential requesters know how to invoke it. The requester, on the other hand,
may have a large repository of information that could be sent; however, it is not
practical to describe all this in a goal. We conjecture that there will be many situa-
tions in which a Web service description contains an accurate interface description,
but a matching goal description does not. That said, if the requester is an automated
agent, there may be a limited number of ways it can interact with services. In this
case, the goal would contain descriptions of the ways the requester can interact with
services. Note that it is, in the general case, unlikely that such interface descriptions
and goals would easily match with interface descriptions in Web services, even if
ontology mapping is applied, thus it might be necessary to use a mediator (see the
next section).

8.2.6 Mediators in WSML

Mediators connect different goals, Web services and ontologies, and enable inter-
operation by reconciling differences in representation formats, encoding styles,
business protocols, etc. Connections between mediators and other WSML elements
can be established in two different ways:

1. Each WSML element allows for the speciﬁcation of a number of used mediators

through the usesMediator keyword.

2. Each mediator has (depending on the type of mediator) one or more sources
and one target. Both source and target are optional in order to allow for generic
mediators.

A mediator achieves its mediation functionality either through a Web service,
which provides the mediation service, or a goal, which can be used to dynamically
discover the appropriate (mediation) Web service.

Listing 8.7 provides an example of ontology-to-ontology mediator that translates

between two different metric units.

8.2.7 Technologies for Using WSML

Interested readers can experiment WSML with a number of technologies. In par-
ticular, the Web Service Modeling Toolkit is an IDE tool to support the design of

8.3 Extensions

153

WSML descriptions, while the WSML2Reasoner framework is a reasoning frame-
work that enables the user to register ontologies belonging to the different variants
of WSML and query the registered knowledge base.

8.2.7.1 The Web Service Modeling Toolkit

The Web Service Modeling Toolkit (WSMT)2 is an integrated development envi-
ronment for Semantic Web Services that enables developers to develop Ontologies,
Web Services, Goals and Mediators through the Web Service Modeling Ontology
(WSMO) formalism. The WSMT is implemented as a collection of plug-ins for the
Eclipse framework such that it can be integrated with other toolkits like the Java
Development Toolkit JDT or the Web Tools Platform (WTP) so that a developer can
develop his Java code, Web services and Semantic Web Services side by side in one
application. The main aim of the WSMT is to support the developer through the
full Software Development Cycle of his Semantic Web Service from requirements,
through design, implementation, testing, and deployment. In this way, the process
of developing Semantic Web Services can be achieved more cheaply, and remove
many of the tedious activities that the developer must currently perform.

As shown in Fig. 8.2, WSMT supports advanced visualization of ontologies and

enables the validation of ontologies over reasoners and their query.

8.2.7.2 WSML2Reasoner

WSML2Reasoner3 is a highly modular framework that combines various validation,
normalization and transformation algorithms that enable the translation of ontology
descriptions in WSML to the appropriate syntax of several underlying reasoning
engines. It ﬁrst maps WSML to either generic Datalog or OWL (OWL1.0), and
then uses a plug-in layer that translates to the speciﬁc internal representation of a
single reasoning engine. Reasoning engines currently integrated and tested within
the WSML2Reasoner framework are: IRIS (WSML-Core, WSML-Flight, WSML-
Rule), KAON2 (WSML-Core, WSML-Flight, WSML-DL), MINS (WSML-Core,
WSML-Flight, WSML-Rule) and PELLET (WSML-Core and WSML-DL). An on-
line demo can be found at: http://tools.sti-innsbruck.at/wsml2reasoner/demos.

8.3 Extensions

The standard ontology languages utilized for service annotation vary with high com-
plexity ranging from PTIME (RDFS and WSML-Core) to NEXPTIME (OWL and

2Available at: http://wsmt.sourceforge.net.
3Available at: http://tools.sti-innsbruck.at/wsml2reasoner/.

154

8 The Web Service Modeling Language

t
i
k
l
o
o
T
g
n
i
l
e
d
o
M

e
c
i
v
r
e
S
b
e
W

e
h
T

2
.
8
e
r
u
g
i
F

8.4 Illustration by a Larger Example

155

WSML-DL). A paradigm shift in constructing ontology languages pushing language
features no longer towards the boundaries of expressivity but eliminating language
features to reach tractability can be observed in recent research on semantics. This
trend leads to the further simpliﬁcation of WSMO to obtain WSMO-Lite and Mi-
croWSMO.

Current ongoing research envisions the following layering:

• WSML-Quark—variant that can be used to tag Web services. This variant is in-
spired by SKOS and contains concept declarations with subConceptOf as the only
allowed relationship.

• WSML-Core v2.0—an evolution of WSML-Core that has minimal expressiv-
ity and thus hugely improved reasoning scalability, ideally with sub-polynomial
complexity.

• WSML-DL v2.0—a new description logic variant of WSML inspired by recent
progress of the OWL 2 family of languages. An OWL 2 proﬁle (equivalent to
ELP) is used as the basis of this new WSML language variant such that useful
expressivity is obtained with minimal computational cost. The semantics of this
new language variant can be captured in Datalog rules and therefore should have
polynomial reasoning complexity.

• WSML-Rule v2.0—a new rule variant of WSML is inspired by recent progress
in the W3C Rule Interchange Format (RIF) and is further modiﬁed such that its
logical expression syntax properly subsumes that of the new WSML-Core v2.0
and WSML-DL, respectively [33].

8.4 Illustration by a Larger Example

In this section, we present a set of WSML description modeling the example sce-
nario of the Virtual Travel Agency ﬁrst introduced in Chap. 4.

In Chap. 7, we collected requirements on semantic descriptions for the scenario.
In this section, starting from those requirements, we present the descriptions needed
to support the scenario. In particular, we will cover a scenario illustrating and ontol-
ogy modeling the travel domain, a Web service of an Austrian railway company, a
service for a international ﬂight company, and a goal to book a trip from Austria to
the UK.

8.4.1 Travel Ontology

The deﬁnition of the ontology is based on the travel itinerary ontology from the
DAML ontology library.4 The ontology deﬁnes basic travel related concepts like
Ticket and Vehicle, as illustrated by the following listing.

4Available at: http://www.daml.org/2001/06/itinerary/itinerary-ont.

156

8 The Web Service Modeling Language

(cid:2)
wsmlVariant _"http://www.wsmo.org/wsml/wsml−syntax/wsml−ﬂight"

namespace {_"http://www.gsmo.org/dip/travel/domainOntology#",

_"http://purl .org/dc/elements/1.1#",

dc
wsml _"http://www.wsmo.org/wsml/wsml−syntax#"}

ontology TravelOntology

concept Ticket
annotations

dc#description hasValue "concept of a ticket "

endAnnotations
from ofType Region
to ofType Region
vehicle ofType Vehicle

concept Region

concept Country subConceptOf Region

name ofType _string

concept City subConceptOf Region

name ofType _string
country ofType Country

concept EUCity subConceptOf City

concept GermanCity subConceptOf EUCity

concept AustrianCity subConceptOf EUCity

concept UKCity subConceptOf EUCity

concept USCity subConceptOf City

concept Vehicle

seats ofType _integer

concept Airplane subConceptOf Vehicle

concept Train subConceptOf Vehicle

axiom GermanCityDef

deﬁnedBy

?city memberOf GermanCity implies ?city[country hasValue Germany].

axiom AustrianCityDef

deﬁnedBy

?city memberOf AustrianCity impliedBy ?city[name hasValue "Austria"] memberOf country.

axiom UKCityDef
deﬁnedBy

?city memberOf UKCity implies ?city[country hasValue UK].

instance Innsbruck memberOf AustrianCity

instance Germany memberOf Country

name hasValue "Germany"

instance UK memberOf Country

name hasValue "United Kingdom"

instance Austria memberOf Country
(cid:4)

name hasValue "Austria"

(cid:3)

(cid:5)

8.4 Illustration by a Larger Example

157

8.4.2 Services

The ﬁrst Web service provides the capability of booking train tickets to travel
within Austria, as expressed by the logic expression fragments ?from memberOf
dO#AustrianCity and ?to memberOf dO#AustrianCity, as presented in the following list-
ing.
(cid:2)
wsmlVariant _"http://www.wsmo.org/wsml/wsml−syntax/wsml−ﬂight"

(cid:3)

namespace {_"http://www.gsmo.org/dip/travel/webServiceAustrianTrains#",

dO _"http://www.gsmo.org/dip/travel/domainOntology#",
dc _"http://purl .org/dc/elements/1.1#"}

webService _"http://www.gsmo.org/dip/travel/webServiceAustrianTrains"

importsOntology _"http://www.gsmo.org/dip/travel/domainOntology#TravelOntology"
capability webServiceAustrianTrainsCapability

postcondition
deﬁnedBy
?ticket [

dO#from hasValue ?from,
dO#to hasValue ?to,
dO#vehicle hasValue ?vehicle
] memberOf dO#Ticket and

?from memberOf dO#AustrianCity and
?to memberOf dO#AustrianCity and
?vehicle memberOf dO#Train.

(cid:4)

(cid:5)

The second Web service provides reservations for ﬂights connecting German and
Austrian cities to other European cities.

(cid:2)
wsmlVariant _"http://www.wsmo.org/wsml/wsml−syntax/wsml−ﬂight"

(cid:3)

namespace {_"http://www.gsmo.org/dip/travel/webServiceFlights#",

dO _"http://www.gsmo.org/dip/travel/domainOntology#",
dc _"http://purl .org/dc/elements/1.1#"}

webService _"http://www.gsmo.org/dip/travel/webServiceFlights"

importsOntology _"http://www.gsmo.org/dip/travel/domainOntology#TravelOntology"
capability webServiceFlightsCapability

postcondition
deﬁnedBy
?ticket [

dO#from hasValue ?from,
dO#to hasValue ?to,
dO#vehicle hasValue ?vehicle

] memberOf dO#Ticket and
(?from memberOf dO#AustrianCity or ?from memberOf dO#GermanCity) and
?to memberOf dO#EuropeanCity and
?vehicle memberOf dO#Airplane.

(cid:5)

(cid:4)

8.4.3 Goal

The following listing presents a goal of buying a ticket from an Austrian city to a
city in the UK. The goal can match only the second Web service, since it is the only
option providing connections between Austria and the UK.

158

8 The Web Service Modeling Language

(cid:2)
wsmlVariant _"http://www.wsmo.org/wsml/wsml−syntax/wsml−ﬂight"

namespace {_"http://www.gsmo.org/dip/travel/goal#",

dO _"http://www.gsmo.org/dip/travel/domainOntology#",
dc _"http://purl .org/dc/elements/1.1#"}

goal _"http://www.gsmo.org/dip/travel/goal.wsml"

importsOntology _"http://www.gsmo.org/dip/travel/domainOntology#TravelOntology"
capability goalCapability

postcondition
deﬁnedBy
?ticket [

dO#from hasValue ?from,
dO#to hasValue ?to
] memberOf dO#Ticket and
?from memberOf dO#AustrianCity and
?to memberOf dO#UKCity.

(cid:4)

8.5 Summary

(cid:3)

(cid:5)

In this chapter, we have introduced various aspects of the Web Service Modeling
Language. We started by introducing principles underlying WSML design. In par-
ticular, we discussed OWL limitations and showed how these limitations can be
overcome by a proper combination of Description Logics and Logic Programming,
by presenting the WSML descriptions of WSMO concepts.

After these initial considerations, we introduced in more detail WSML variants
and their layering in order to achieve the maximum ﬂexibility in term of expressive
power of the language. WSML enables going from the maximum common inter-
section of Description Logics and Logic Programming to the minimum common
conjunction of them. The discussion on WSML variants is followed by a detailed
introduction to WSML syntax, covering all the WSML elements: ontologies, ser-
vices, goals and mediators. We also provided a quick insight to tools that students
can use to create and test WSML descriptions, and discussed extensions of WSML
to support large scale reasoning and compatibility with OWL2 and RIF.

The chapter has concluded with the presentation of WSML descriptions for the

scenario introduced in Chap. 4.

8.6 Exercises

Exercise 1 According to the Blue Hotel service example discussed in Chap. 4,
create an ontology for the description of the hotel domain and a service descrip-
tion for the Blue Hotel. In the service description, also include the deﬁnition of the
choreography.

Exercise 2 Extend the travel ontology presented in Sect. 8.4 by introducing the
bus travels, timetables and routes. Deﬁne a service for the public transport system
of Innsbruck capable of providing the departures from a given bus stop and the next
bus stop on the route.

8.6 Exercises

159

Exercise 3 Deﬁne a goal for booking a double room for non-smokers, according
to the ontology modeled in Exercise 3.

Exercise 4 Consider the ontology in the following listing, representing knowledge
about a famous American cartoon.

(cid:3)

(cid:2)
wsmlVariant _"http://www.wsmo.org/wsml/wsml−syntax/wsml−ﬂight"
namespace { _"http://ontologies.sti2.at/"
,

wsml _"http://www.wsmo.org/wsml/wsml−syntax#",
dc _"http://purl .org/dc/elements/1.1/" }

ontology simpsons

concept gender

concept character

hasName ofType _string
hasGender ofType gender
hasSpouse ofType character
hasChild ofType character
hasParent ofType character
hasSibling ofType character
hasFriend ofType character
hasCatchPhrase ofType _string
inLoveWith ofType character
isCustomerOf ofType workplace
hasWorkingPlace ofType place
attends ofType school

instance male memberOf gender

instance female memberOf gender

instance homer_simpson memberOf character

annotations

dc#title hasValue "Homer J Simpson"

endAnnotations
hasName hasValue "Homer J Simpson"
hasGender hasValue male
hasSpouse hasValue marge_simpson
hasParent hasValue abe_simpson
hasChild hasValue {bart_simpson, lisa_simpson, maggie_simpson }

instance marge_simpson memberOf character

annotations

dc#title hasValue "Marge Simpson"

endAnnotations
hasName hasValue "Marge Simpson"
hasGender hasValue female
hasSpouse hasValue homer_simpson
hasChild hasValue {bart_simpson, lisa_simpson, maggie_simpson }
hasSibling hasValue {patty_bouvier, selma_bouvier }

instance lisa_simpson memberOf character

annotations

dc#title hasValue "Lisa Simpson"

endAnnotations
hasName hasValue "Lisa Simpson"
hasGender hasValue female
hasParent hasValue {homer_simpson, marge_simpson }
hasSibling hasValue {bart_simpson, maggie_simpson }

instance bart_simpson memberOf character

annotations

160

(cid:4)

dc#title hasValue "Bart Simpson"

endAnnotations
hasName hasValue "Bart Simpson"
hasGender hasValue male
hasParent hasValue {homer_simpson, marge_simpson }

Deﬁne

8 The Web Service Modeling Language

(cid:5)

1. An axiom that states that all married people are in love with their spouse (Hint:

similar to the axioms from the travel Ontology example).

2. A logical expression to ﬁnd out who is in love with whom in the Simpsons world
(Hint: logical expressions are modeled using axioms, for example, hasTempera-
tureObserviationAxiom).

3. A axiom that states that if a character A is sibling with a character B then also

the B is sibling with A.

4. A axiom that deﬁnes the mother of a character as parent of female gender.
5. A axiom that states that male and female characters are disjoint.

References

1. Baader, F., Calvanese, D., McGuinness, D.L., Nardi, D., Patel-Schneider, P.F. (eds.): The De-

scription Logic Handbook. Cambridge University Press, Cambridge (2003)

2. Biron, P.V., Malhotra, A.: XML schema part 2: Datatypes second edition. Recommendation

28 October 2004, W3C (2004). http://www.w3.org/TR/xmlschema-2/

3. de Bruijn, J., Polleres, A., Lara, R., Fensel, D.: OWL DL vs. OWL Flight: Conceptual model-
ing and reasoning on the Semantic web. In: Proceedings of the 14th International World Wide
Web Conference (WWW2005), Chiba, Japan, pp. 623–632. ACM, New York (2005)

4. de Bruijn, J., Eiter, T., Polleres, A., Tompits, H.: On representational issues about combina-
tions of classical theories with nonmonotonic rules. In: Proceedings of the 1st International
Conference on Knowledge Science, Engineering and Management (KSEM2006), pp. 1–22.
Springer, Berlin (2006)

5. de Bruijn, J., Eiter, T., Polleres, A., Tompits, H.: Embedding non-ground logic programs into
autoepistemic logic for knowledge-base combination. In: Proceedings of the 20th Interna-
tional Joint Conference on Artiﬁcial Intelligence (IJCAI2007), January 6–12, Hyderabad, In-
dia, pp. 304–309. AAAI Press, Menlo Park (2007)

6. de Bruijn, J., Heymans, S.: A semantic framework for language layering in WSML. In:
Proceedings of the First International Conference on Web Reasoning and Rule Systems
(RR2007), June 7–8, Innsbruck, Austria, pp. 103–117. Springer, Berlin (2007)

7. de Bruijn, J., Heymans, S.: WSML ontology semantics. Working Draft d28.3, WSML Working

Group (2007). http://www.wsmo.org/TR/d28/d28.3/v0.2/

8. de Bruijn, J., Pearce, D., Polleres, A., Valverde, A.: Quantiﬁed equilibrium logic and hybrid
rules. In: Proceedings of the 1st International Conference on Web Reasoning and Rule Systems
(RR2007), June 7–8, Innsbruck, Austria, pp. 58–72. Springer, Berlin (2007)

9. de Bruijn, J., Fensel, D., Kerrigan, M., Keller, U., Lausen, H., Scicluna, J.: Modeling Semantic

Web Services: The Web Service Modeling Language. Springer, Berlin (2008)

10. Dean, M., Schreiber, G.: OWL web ontology language reference. Recommendation 10 Febru-

ary 2004, W3C (2004). http://www.w3.org/TR/owl-ref/

11. Duerst, M., Suignard, M.: Internationalized resource identiﬁers (IRis). Proposed standard RFC

3987, Internet Engineering Task Force (2005)

References

161

12. Eiter, T., Lukasiewicz, T., Schindlauer, R., Tompits, H.: Combining answer set programming
with description logics for the Semantic Web. In: Proceedings of the 9th International Con-
ference on Principles of Knowledge Representation and Reasoning (KR2004). AAAI Press,
Menlo Park (2004)

13. Fensel, D., Lausen, H., Polleres, A., de Bruijn, J., Stollberg, M., Roman, D., Domingue, J.:
Enabling Semantic Web Services—The Web Service Modeling Ontology. Springer, Berlin
(2006)

14. Grosof, B.N., Horrocks, I., Volz, R., Decker, S.: Description logic programs: Combining logic
programs with description logic. In: Proc. Int. Conf. on the World Wide Web (WWW-2003),
Budapest, Hungary (2003)

15. Group, W.W.: WSML language reference. Final Draft D16.1 v1.0, WSML (2008).

http://www.wsmo.org/TR/d16/d16.1/v1.0/

16. Hiddlers, J., Paredaens, J.: Encyclopedia of Database Systems (2009)
17. Horrocks, I., Patel-Schneider, P.F.: A proposal for an OWL rules language. In: WWW ’04:
Proceedings of the 13th International Conference on World Wide Web, pp. 723–731. ACM,
New York (2004). doi:10.1145/988672.988771

18. Jacobs, I.: Architecture of the World Wide Web, volume one. Recommendation 15 December

2004, W3C (2004). http://www.w3.org/TR/webarch/

19. Kifer, M., de Bruijn, J., Boley, H., Fensel, D.: A realistic architecture for the Semantic Web.
In: Proceedings of the International Conference on Rules and Rule Markup Languages for
the Semantic Web (RuleML-2005), Ireland, Galway. Lecture Notes in Computer Science,
vol. 3791, pp. 17–29. Springer, Berlin (2005)

20. Kifer, M., Lausen, G., Wu, J.: Logical foundations of object-oriented and frame-based lan-

guages. Journal of the ACM 42(4), 741–843 (1995)

21. Levy, A.Y., Rousset, M.-C.: Combining horn rules and description logics in CARIN. Artiﬁcial

Intelligence 104, 165–209 (1998)

22. McGuinness, D.L., van Harmelen, F.: OWL web ontology language overview. Recommenda-
tion 10 February 2004, W3C (2004). Available from http://www.w3.org/TR/owl-features/
23. Mocan, A.: Ontology-based data mediation for semantic environments. PhD Thesis, National

University of Ireland (2008)

24. Motik, B., Rosati, R.: A faithful integration of description logics with logic programming. In:
Proceedings of the Twentieth International Joint Conference on Artiﬁcial Intelligence (IJCAI-
07), Hyderabad, India (2007)

25. Motik, B., Horrocks, I., Rosati, R., Sattler, U.: Can owl and logic programming live together
happily ever after? In: Proc. of the 5th Int. Semantic Web Conf. (ISWC 2006), Athens, GA,
USA (2006)

26. O’Sullivan, J., Edmond, D., ter Hofstede, A.H.: Formal description of non-functional ser-
vice properties. Technical report, Queensland University of Technology, Brisbane (2005).
http://www.service-description.com/

27. Polleres, A., Scharffe, F., Schindlauer, R.: SPARQL++ for mapping between RDF vocabu-
laries. In: OTM 2007, Part I: Proceedings of the 6th International Conference on Ontologies,
DataBases, and Applications of Semantics (ODBASE 2007), Vilamoura, Algarve, Portugal,
pp. 878–896. Springer, Berlin (2007)

28. Przymusinski, T.C.: On the declarative and procedural semantics of logic programs. Journal

of Automated Reasoning 5(2), 167–205 (1989)

29. Roman, D., Lausen, H., Keller, U.: Web service modeling ontology (WSMO). Final Draft

D2v1.3, WSMO (2006). http://www.wsmo.org/TR/d2/v1.3/

30. Rosati, R.: DL +log: tight integration of description logics and disjunctive datalog. In:

KR2006 (2006)

31. Scharffe, F., de Bruijn, J.: A language to specify mappings between ontologies. In: Proceed-
ings of the 1st International Conference on Signal-Image Technology and Internet-Based Sys-
tems (SITIS2005). Dicolor Press, Yandoué (2005)

32. Toma, I., Foxvog, D., Jaeger, M.C.: Modeling QoS characteristics in WSMO. In: Proceed-
ings of the 1st Workshop on Middleware for Service Oriented Computing (MW4SOC 2006),
Melbourne, Australia, pp. 42–47 (2006)

162

8 The Web Service Modeling Language

33. Toma, I., Bishop, B., Fischer, F.: Deﬁning the features of the WSML-Rule v2.0 language.

SOA4All Deliverable D3.1.4 (2009)

34. Weibel, S., Kunze, J., Lagoze, C., Wolf, M.: Dublin core metadata for resource discovery. RFC

2413, IETF (1998)

Chapter 9
The Web Service Execution Environment

Abstract Computer science is on the edge of an important new period of abstrac-
tion. A generation ago we learned to abstract from hardware and currently we learn
to abstract from software in terms of Service Oriented Architectures (SOA). A Ser-
vice Oriented Architecture is essentially a collection of services. However, we be-
lieve that these SOAs will not scale without signiﬁcant mechanization of service
discovery, service adaptation, service negotiation, service composition, service in-
vocation, and service monitoring, as well as data-, protocol-, and process-mediation.
We envisage the future of applied computer science in terms of service-oriented ar-
chitectures which is empowered by adding semantics as a means of dealing with
heterogeneity and mechanization of service usage. This approach is called Semanti-
cally Enabled Service-oriented Architectures, or SESA for short. In this chapter, we
give an introduction to SESA and Web Service Execution Environment (WSMX)
as its most prominent implementation. First, we are motivating the SESA approach,
followed by an analysis of SESA vision, and governing principles. Special attention
is paid to the notion of Execution Semantics, basic SESA services and WSMX. The
elaboration is followed by a larger example demonstrating steps needed to achieve
a WSMO goal.

9.1 Motivation

In this section, we provide an overview of the fundamental elements of the SESA
architecture, which enable the execution of Semantic Web Services (SWS) and re-
solve the fundamental challenges related to the open SOA environment. We expect
that in the near future a service-oriented world will consist of an extremely high
number of services. Their computation will involve services searching for other ser-
vices based on functional and non-functional requirements, and then resolving any
interoperability conﬂicts from the services selected. However, services will not be
able to interact automatically and existing SOA solutions will not scale without
signiﬁcant mechanization of the service provisioning process. Hence, machine pro-
cessable semantics is essential for the next generation of service-oriented computing
to reach its full potential. In this chapter, we deﬁne methods, algorithms and tools
forming a skeleton of SESA, introducing automation to the service provisioning pro-
cess including service discovery, negotiation, adaptation, composition, invocation,

D. Fensel et al., Semantic Web Services,
DOI 10.1007/978-3-642-19193-0_9, © Springer-Verlag Berlin Heidelberg 2011

163

164

9 The Web Service Execution Environment

and monitoring, as well as service interaction requiring data and process media-
tion. SOA outside of a tightly controlled environment cannot succeed until semantic
issues are addressed and critical tasks within the service provisioning process are
automated, leaving humans to focus on higher level aspects like problem-solving
and business processes. This chapter describes how these building blocks are con-
solidated into a coherent software architecture which can be used as a blueprint for
implementation.

9.1.1 Service Orientation

The design of enterprise information systems has gone through several changes in
recent years. In order to respond to the requirements of enterprises for ﬂexibility
and dynamism, the traditional monolithic applications have become substituted by
smaller composable units of functionality known as services. Information systems
must then be re-tailored to ﬁt this paradigm, with new applications developed as
services, and legacy systems to be updated in order to expose service interfaces.
The drive is towards a design of information systems based on Service Oriented
Computing (SOC) paradigm, SOA implementation architecture and relevant Web
service technologies.

9.1.1.1 Service Oriented Computing

Service Oriented Computing (SOC) is a new computing paradigm that utilizes ser-
vices as the fundamental elements for the development of rapid, low-cost and easily
integrable enterprise applications [17, 20]. One of the main goals of SOC is to en-
able the development of networks of the integrated and collaborative applications,
regardless of both the platform where applications or services run (e.g., the operat-
ing system) and programming languages used to develop them.

In this paradigm, services are autonomous, self-describing and platform-indepen-
dent computational entities which provide uniform and ubiquitous access to infor-
mation for a wide range of computing devices (such as desktops, PDAs, cellular
phones) and software programs across different platforms. Any piece of code and
any application component deployed in a system can be reused and transformed into
a network-wide available service, while service providers and service consumers re-
main loosely coupled.

The main goal of SOC is to facilitate the integration of newly built and legacy
applications which exist both within and across organizational boundaries. SOC
must overcome and resolve conﬂicts due to different platforms, programming lan-
guages, security ﬁrewalls, etc. The basic idea behind this service-orientation is to
allow applications which were developed independently (using different languages,
technologies, or platforms) to be exposed as services and then interconnect them
exploiting the Web infrastructure with respective standards such as HTTP, XML,
SOAP, WSDL, and complex service orchestration standards like BPEL.

9.1 Motivation

Fig. 9.1 Web Services
Programming Model

165

9.1.1.2 Service Oriented Architectures

The service oriented paradigm of computation can be abstractly implemented by
the system architecture called Service Oriented Architecture (SOA) [1, 2]. The pur-
pose of this architecture is to address the requirements of loosely coupled, standard-
based, and protocol-independent distributed computing, mapping enterprise infor-
mation systems isomorphically to the overall business process ﬂow [19]. This at-
tempt is considered to be the latest development in a long series of advancements in
software engineering addressing the reuse of software components.

Historically, the ﬁrst major step of this evolution has been the development of
the concept of a function. Using functions, a program is decomposed into smaller
subprograms, while writing code is focused on the notion of the application pro-
gramming interface (API). An API, practically, represents the contract to which a
software component must commit. The second major step was the development of
the notion of an object. An object is a basic building block which contains both data
and functions within a single encapsulated unit. With the object-oriented paradigm,
the notions of classes, inheritance and polymorphism were introduced. The concept
of a service becomes the next evolutionary step introduced with the advent of SOC
and SOA.

The following Fig. 9.1 is the Web Services Programming Model which consists
of three components: service consumers, service providers and service registrars.
Ignoring the detailed techniques for the connection of the three components, this
model also represents the SOA basic model. A service registrar (also known as
service broker) acts as an intermediary between the provider and the consumer, so
that they are able to ﬁnd each other. A service provider simply publishes the service.
A service consumer tries to ﬁnd services using the registrar; if it ﬁnds the desired
service it can set up a contract with the provider in order to consume such a service.
The fundamental logic view of services in SOA is based on the division of ser-
vice description (called usually interface) and service implementation [19]. Service
interface deﬁnes the identity of a service and its invocation logistics. Service im-
plementation implements the functionality that the service is designated to provide.

166

9 The Web Service Execution Environment

Following this division, service providers and services consumers are loosely cou-
pled. Furthermore, the services can be to a large extent reused and adapted accord-
ing to certain requirements. Because service interfaces are platform independent
and implementation is transparent to the service consumers, a client using any com-
munication device on any computational platform, operating system and any pro-
gramming language should be capable of using the service. The two facets of the
service are distinct; they are designed and maintained as distinct items, though their
existence is highly interrelated.

SOA provides a more ﬂexible architecture for realizing distributed applications
than its predecessor approaches (e.g., CORBA) by unifying business processes by
modularizing large applications into services. Furthermore, enterprise-wide or even
cross-enterprise applications can be realized by means of services development, in-
tegration, and adaptation. Any system that claims to be SOA compliant must fulﬁll
a set of requirements that were identiﬁed and analyzed in [21]:

• Loose Coupling Interacting services are loosely coupled by nature. They run on
different platforms, are implemented independently and have different owners.
The model has to consider the loose coupling of services with respect to one
another.

• Implementation Neutrality The interface should be the thing that matters, not
its implementation. Services are deﬁned independently of their implementation
and, with respect to them, should behave neutrally.

• Flexible Conﬁguration Services are invoked dynamically after the discovery
process through the service requestor. That is, the binding of a service provider
to the requester occurs at run time in the ﬁnal phase.

• Long Lifetime Components/services should exist long enough to be discovered,

relied upon, and engender trust in their behavior.

• Granularity The granularity of a service deﬁnes the complexity and number of
functionalities deﬁned by an individual service and is thus part of the service
model. An appropriate balance between coarse and ﬁne grained services depends
on the way services are modeled. For too ﬁne grained services, problems arise
when there are frequent and rapid changes.

• Teams Computation in open systems should be conceptualized as business part-
ners working as a team. Therefore, a team of cooperating autonomous compo-
nents/services is a better modeling unit, as opposed to framing computations cen-
trally.

Besides the basic SOA model shown in Fig. 9.1, there are a few extension
works towards SOA, which include more detailed concepts. The Extended Service-
Oriented Architecture (xSOA) accounts for SOA deﬁciencies in such areas as man-
agement, security, service choreography and orchestration, and service transaction
management and coordination [16]. The xSOA is an attempt to streamline, group to-
gether and logically structure the functional requirements of complex applications
that make use of the SOC computing paradigm. xSOA provides a layer server-based
architecture that extends conventional SOA and provides a logical separation of con-
cerns. Extensions, such as xSOA, are steps towards deﬁning a more accurate and

9.1 Motivation

167

detailed picture of SOA components. In the following subsections, after discussing
how SOA can be implemented, we propose a set of semantic-based extensions to
SOA that will enable automation support for service related tasks.

9.1.1.3 SOA Implementations

Web services become the preferred implementation technology for realizing the
SOA promise of maximum service sharing, reuse, and interoperability. As illus-
trated in Fig. 9.1, the Web service programming model is a typical SOA imple-
mentation. Its central concept is the concept of a Web service that is deﬁned by
W3C as a software system identiﬁed by a URI whose public interfaces and bind-
ings are deﬁned and described using XML. Its deﬁnition can be discovered by other
software systems. These systems may then interact with the Web service in a man-
ner prescribed by its deﬁnition, using XML based messages conveyed by Internet
protocols. Interactions between Web services typically occur as Simple Object Ac-
cess Protocol (SOAP) calls carrying XML data content. Interface descriptions of
the Web services are expressed using Web Services Deﬁnition Language (WSDL).
The Universal Description, Discovery, and Integration (UDDI) standard deﬁnes a
protocol for directory services that contain Web service descriptions. UDDI enables
Web service clients to locate candidate services and discover their details. Service
clients and service providers utilize these standards to perform SOA’s basic oper-
ations. Service aggregators may use the Business Process Execution Language for
Web Services (BPEL4WS) to create new Web services by deﬁning corresponding
compositions of the interfaces and internal processes of existing services.

Web services technology is a widespread accepted instantiation of SOC provid-
ing a platform on which it is possible to develop applications taking advantage of the
already existing Internet infrastructure. This does not mean that the set of technolo-
gies we are presenting are the only ones which make possible the realization and im-
plementation of SOC and SOA. Other, more conventional programming languages
or middleware platforms may be adopted as well, such as, for instance, established
middleware technologies like J2EE, CORBA and IBM’s WebSphere MQ, which can
now also participate in an SOA, using new features that work with WSDL.

The broad use of Enterprise Application Integration (EAI) middleware support a
variety of hub-and-spoke integration patterns [18]. EAI comprises message accep-
tance, transformation, translation, routing, message delivery and business process
management. All of these can be used to develop services and service orientated ar-
chitectures. The Enterprise Service Bus (ESB) is an open, standards-based message
bus designed to enable the implementation, deployment, and management of SOA
based solutions with a focus on assembling, deploying, and managing distributed
SOAs. The ESB provides the distributed processing, standards based integration,
and enterprise-class backbone required by the extended enterprise [13].

168

9 The Web Service Execution Environment

9.1.2 Execution Environment for Semantic Web Services

With the underpinning computation approach SOC, SOA is one of the most promis-
ing software engineering trends for future distributed systems. Pushed by major
industry players and supported by many standardization efforts, Web services are a
prominent implementation of the service-oriented paradigm. They promise to foster
reuse and to ease the implementation of loosely coupled distributed applications.

Although the idea of SOA targets the need for integration that is more adaptive
to changes in business requirements, existing SOA solutions will prove difﬁcult to
scale without a proper degree of automation. While today’s service technologies
around WSDL, SOAP, UDDI, and BPEL certainly brought a new potential to SOA,
they only provide a partial solution to interoperability, mainly by means of uni-
ﬁed technological environments. Where content and process level interoperability
is to be solved, ad-hoc solutions are often hard-wired in a manual conﬁguration of
services or workﬂows while at the same time they are hindered by dependence on
XML-only descriptions. Although ﬂexible and extensible, XML can only deﬁne the
structure and syntax of data. Without machine-understandable semantics, services
must be located and bound to service requesters at design-time which, in turn, lim-
its possibilities for automation. In order to address these drawbacks, the extension
of SOA with semantics offers a scalable integration, more adaptive to changes that
might occur over a software systems lifetime. Semantics for SOA allow the deﬁni-
tion of semantically rich and formal service models where semantics can be used
to describe both services offered and capabilities required by potential consumers
of those services. The data to be exchanged between business partners can also
be semantically described in an unambiguous manner in terms of ontologies. By
means of logical reasoning, semantic SOA thus promotes a total or partial automa-
tion of service discovery, mediation, composition and invocation. Semantic SOA
is not, however, meant to replace existing integration technologies. The goal is to
build a new layer on the top of existing service stack while at the same time adopt
existing industry standards and technologies being used within existing enterprise
infrastructures.

9.1.3 Governing Principles

We have identiﬁed a number of underlying principles which govern the design of
the architecture, its middleware, as well as the modeling of business services. These
principles reﬂect fundamental aspects for service-oriented and distributed environ-
ments which promote intelligent and seamless integration and provisioning of busi-
ness services. These principles include:

• Service Oriented Principle represents a distinct approach for analysis, design,
and implementation which further introduces particular principles that govern as-
pects of communication, architecture, and processing logic. This includes service

9.2 Technical Solution

169

reusability, loose coupling, abstraction, composability, autonomy, and discover-
ability.

• Semantic Principle allows a rich and formal description of information and be-
havioral models enabling automation of certain tasks by means of logical reason-
ing. Combined with the service oriented principle, semantics allows the deﬁnition
of scalable, semantically rich and formal service models and ontologies allowing
the promotion of total or partial automation of tasks such as service discovery,
contracting, negotiation, mediation, composition, invocation, etc.

• Problem Solving Principle reﬂects Problem Solving Methods as one of the fun-
damental concepts of Artiﬁcial Intelligence. It underpins the ultimate goal of the
architecture which lies in the so-called goal-based discovery and invocation of
services. Users (service requester’s) describe requests as goals semantically and
independently from services, while architecture solves those goals by means of
logical reasoning over goals’ and services’ descriptions. Ultimately, users do not
need to be aware of processing logic but only care about the result and its desired
quality.

• Distributed Principle allows aggregation of the power of several computing en-
tities to collaboratively run a task in a transparent and coherent way, so that from
service requester’s perspective they can appear as a single and centralized system.
This principle allows executing a process across a number of components/ser-
vices over the network which, in turn, can promote scalability and quality of the
process.

9.2 Technical Solution

9.2.1 SESA Vision

The global view on the architecture, depicted in Fig. 9.2, comprises several lay-
ers, namely (i) Stakeholders forming several groups of users of the architecture,
(ii) Problem Solving Layer building the environment for stakeholders to access the
architecture, (iii) Service Requesters as client systems of the architecture, (iv) Mid-
dleware providing intelligence for the integration and interoperation of business ser-
vices, and (v) Service Providers exposing the functionality of back-end systems as
Business Services. In this section, we describe these layers and deﬁne service types
within the architecture, as well as underlying concepts and technology we use for
architecture implementation.

As part of the ﬁve layers infrastructure illustrated in Fig. 9.2, four types of ser-

vices are provided:

• The stakeholders’ layer services which consist of Ontologies, Applications
(e.g., e-tourism, e-government) and Developer tools (GUI tools such as those for
engineering ontology/Web Service descriptions; generic developer tools such as
language APIs, parsers/serializers, converters, etc.).

170

9 The Web Service Execution Environment

e
r
u
t
c
e
t
i
h
c
r
a
A
S
E
S
n
o
w
e
i
v
l
a
b
o
l
G

2
.
9

.
g
i
F

9.2 Technical Solution

171

• Broker services which consist of Discovery, Adaptation (including selection and
negotiation), Composition (Web Service composition techniques such as plan-
ning), Choreography, Mediation ((a) Ontology mediation—techniques for com-
bining Ontologies and for overcoming differences between Ontologies; (b) Pro-
cess mediation—overcoming differences in message ordering, etc.), Grounding,
Fault Handling (Transactionality, Compensation, etc.), and Monitoring.

• Base services that are providing the exchange formalism used by the architecture,
i.e., Formal languages (static ontology and behavioral, i.e., capability/choreogra-
phy/orchestration languages, connection between higher-level descriptions, e.g.,
WSML), Reasoning (techniques for reasoning over formal descriptions; LP, DL,
FOL, behavioral languages, etc.), and Storage and Communication.

• Finally, vertical services such as Execution management and Security (authenti-

cation/authorization, encryption, trust/certiﬁcation).

9.2.1.1 Stakeholders’ Layer

Stakeholders are the users of the functionality of the architecture. Two basic groups
of stakeholders are identiﬁed: users and experts. For users the architecture provides
end-user functionality through specialized applications. For example, users can per-
form electronic exchange of information to acquire or provide products or services,
to place or receive orders and to perform ﬁnancial transactions. In general, the goal
is to allow users to interact with business processes online while simultaneously
reducing their physical interactions with back-ofﬁce operations. Experts perform
development and administrative tasks in the architecture. These tasks support the
entire SOA life cycle including service modeling, creation (assembling), deploy-
ment (publishing), and management. Different types of experts could be involved in
this process ranging from domain experts (modeling, creation), system administra-
tors (deployment, management) and software engineers.

9.2.1.2 Problem Solving Layer

The Problem Solving layer contains applications and tools which support stakehold-
ers during the formulation of problems/requests and generates descriptions of such
requests in the form of user goals. Through the Problem Solving layer, users are
able to solve their problems, i.e., formulate a problem, interact with the architecture
during processing and get their desired results. This layer contains back-end sys-
tems which directly connect the middleware within business processes, specialized
applications built for speciﬁc purposes in a particular domain, which also provide
speciﬁc domain ontologies, and developer tools providing functionality for devel-
opment and administrative tasks within the architecture. Developer tools provide a
speciﬁc functionality for experts, i.e., domain experts, system administrators and
software engineers. The functionality of developer tools cover the whole SOA life
cycle including service modeling, creation (assembling), deployment (publishing),

172

9 The Web Service Execution Environment

and management. Using tools such as these, a developer will be able to create and
manage ontologies, Web Services, goals and mediators, create ontology-to-ontology
mediation mappings and deploy these mappings to the middleware.

9.2.1.3 Service Requesters’ Layer

Service requesters act as client systems in a client–server setting of the architec-
ture. Their requests are represented as goals created through problem/request for-
mulation as well as interfaces through which conversation with potential services is
expressed.

9.2.1.4 Middleware Layer

Middleware is the core of the architecture, providing the intelligence for the integra-
tion and interoperation of Business Services. For the SESA purposes, we call this
middleware Semantic Execution Environment. The architecture deﬁnes the neces-
sary conceptual functionality that is imposed on the architecture through the un-
derlying principles deﬁned in Sect. 9.1. Each such functionality could be real-
ized (totally or partially) by a number of the so-called middleware services (see
Sect. 9.2.1.6). We further distinguish this functionality through the following lay-
ers: base layer, broker layer, and vertical layer.

Vertical Layer The Vertical layer deﬁnes the middleware framework function-
ality that is used across the Broker and Base Layers but which remains invisible to
them. This technique is best understood through the so-called “Hollywood Princi-
ple” that basically means “Don’t call us, we’ll call you”. In this respect, framework
functionality always consumes functionality of Broker and Base Layers, coordi-
nating and managing overall execution processes in the middleware. For example,
Discovery or Data Mediation is not aware of the overall coordination and distributed
mechanism of the Execution Management.

• Execution Management deﬁnes control of various execution scenarios (called
execution semantics) and handles distributed execution of middleware services.
• Security deﬁnes secure communication, i.e., authentication, authorization, conﬁ-
dentiality, data encryption, traceability or non-repudiation support applied within
execution scenarios in the architecture.

Broker Layer The Broker layer deﬁnes the functionality which is directly re-
quired for a goal based invocation of Semantic Web Services. The Broker Layer
includes:

• Discovery which deﬁnes tasks for identifying and locating of business services

which can achieve a requester’s goal.

• Choreography which deﬁnes formal speciﬁcations of interactions and processes

between the service providers and the client.

9.2 Technical Solution

173

• Monitoring which deﬁnes monitoring of the execution of end point services; this
monitoring may be used for gathering information on invoked services, e.g., QoS
related or in identifying faults during execution.

• Fault Handling which deﬁnes handling of faults occurring within execution of

end point Web Services.

• Adaptation which deﬁnes an adaptation within particular execution scenario ac-
cording to user preferences (e.g., service selection, negotiation, contracting).
• Mediation which deﬁnes interoperability at the functional, data and process lev-

els.

• Composition which deﬁnes a composition of services into an executable work-
ﬂow (business process). It also includes orchestration which deﬁnes the execution
of a composite process (business process) together with a conversation between a
service requester and a service provider within that process.

• Grounding which deﬁnes a link between semantic level and a non-semantic level

(e.g., WSDL) used for service invocation.

Base Layer The Base layer deﬁnes functionality that is not directly required in a
goal based invocation of business services; however, they are required by the Broker
Layer for successful operation. Base layer includes:
• Formal Languages which deﬁne syntactical operations (e.g., parsing) with se-
mantic languages used for semantic description of services, goals and ontologies.

• Reasoning which deﬁnes reasoning functionality over semantic descriptions.
• Storage and Communication which deﬁne persistence mechanism for various
elements (e.g., services, ontologies) as well as inbound and outbound communi-
cation of the middleware.

The SESA middleware can operate in a distributed manner when a number of
middleware systems connected using a shared message space operate within a net-
work of middleware systems and empowering this way a scalability of integration
processes. SESA consists of several decoupled services. These services can be re-
ﬁned and extended. Each of these services can have its own structure without hinder-
ing the overall SESA architecture. Following the SOA design principles, the SESA
architecture separates concerns of individual middleware services, thereby separat-
ing service descriptions and their interfaces from implementation. This adds ﬂexi-
bility and scalability for upgrading or replacing the implementation of middleware
services which adhere to required interfaces.

9.2.1.5 Service Providers’ Layer

Service providers represent various back-end systems. Unlike back-end systems in
the service requesters’ layer which act as clients in the client–server setting of the ar-
chitecture, the back-end systems in the service providers’ layer act as servers which
provide certain functionality for a certain purpose exposed as a business service
to the architecture. Depending on the particular architecture deployment and inte-
gration scenario, the back-end systems could originate from one organization (one

174

9 The Web Service Execution Environment

service provider) or multiple organizations (more service providers) interconnected
over the network (Internet, intranet or extranet). The architecture thus can serve var-
ious requirements for Business-to-Business (B2B) integration, Enterprise Applica-
tion Integration (EAI) or Application-to-Application (A2A) integration. In all cases,
functionality of the back-end systems is exposed as semantically described business
services.

9.2.1.6 Services in SESA

Most of the SESA functionality is provided as services, while a very small part of
the functionality required for the overall management is not. While the Middleware
and Service requesters’ layers build SESA architecture in terms of services (with
some exceptions), the Problem Solving layer adds the set of tools and entities which
make SESA a fully-ﬂedged Semantic Service-Oriented Architecture.

The core aspect of SOA is the service. In this respect, we distinguish between
two types of services in SESA, namely middleware services and business services.

1. Middleware Services are necessary to enable some particular functionality of
the architecture—they are the main facilitators for integration, search, and medi-
ation of business services.

2. Business Services are exposed by service providers whose back-end systems are
external to SESA. Business services are subject of integration and interoperation
within the architecture (facilitated by the middleware services) and usually pro-
vide a certain value for architecture stakeholders. Such services are semantically
described in the SESA architecture, conforming to a speciﬁc semantic service
model.

SESA deﬁnes the scope of particular middleware services in terms of the func-
tionality they should provide. In addition, it deﬁnes a semantic service model for
the business services on which it operates. Business services are modeled in accor-
dance to the requirements of the application scenario in which they are used. For
this purpose, domain-speciﬁc ontologies can be designed as part of SESA applica-
tion design or evaluation. With respect to middleware services and business services
distinction, the SESA middleware is designed as the Service Oriented Architecture
on its own. However, it serves as a facilitator for the integration of semantic business
services and as such is not currently considered as semantically-enabled but rather
as semantics-enabling. Illustrating the above, Fig. 9.3 depicts middleware and busi-
ness services within the scope of SESA architecture.

9.2.1.7 Underlying Concepts and Technology

The SESA architecture builds on the underlying concepts and technologies and fur-
ther extends speciﬁcations around conceptual model deﬁned by Web Service Mod-
eling Ontology (WSMO), Web Service Modeling Language (WSML), and the ref-
erence middleware implementation called WSMX. WSMO (see Chap. 7) provides a

9.2 Technical Solution

175

Fig. 9.3 Middleware services and business services

conceptual model describing all relevant aspects of Web Services in order to facili-
tate the total or partial automation of service discovery, composition and invocation.
The description of WSMO elements is represented using the WSML family of on-
tology languages (see Chap. 8) which consists of a number of variants based on
different logical formalisms and different levels of logical expressiveness. WSMO
and WSML thus provide grounds for semantic modeling of services as well as for a
Semantic Web services based middleware system which speciﬁcally enacts Seman-
tic Service Oriented Architectures. Reference implementation of this middleware
system is called WSMX. WSMO is the model being developed for modeling of
business services. WSMX is the reference implementation of the SESA and pro-
vides various middleware services which facilitate integration of semantic business
services. In addition, Web Service Modeling Toolkit (WSMT) provides an end-user
IDE for modeling of business services and run-time management of the middleware
environment.

9.2.2 SESA Middleware

This section provides a technical description for the middleware layer of the SESA
architecture, introduced in the last section, following the view-centric guidelines
of the IEEE Recommended Practice for Architectural Descriptions of Software-

176

9 The Web Service Execution Environment

intensive systems (IEEE 14711). We look in more detail at the functionality re-
quired by each of the middleware services and suggest technology-neutral interfaces
for them. This section also includes a description of the technology used to design
and implement an open source prototype for the SESA middleware. The last sec-
tion provided a high-level view of what is meant by SESA. This section extends
the technical description by providing a view on the processes supported by SESA
and how they are deﬁned in two additional views: (i) Services View—functional
descriptions and interfaces of the middleware and base services and (ii) Technol-
ogy View—a look at the technology used in the design and implementation of the
WSMX prototype for SESA.

9.2.2.1 Services Viewpoint

Services are the basic building blocks of the SESA architecture. In other words,
SESA uses a Service-Oriented Architecture to provide an intelligent middleware
for service-oriented applications. This means that the middleware services provided
by SESA can themselves be used by SESA to allow for exchanging data models,
process strategies, implementations or policy.

In the following subsections, we describe the three middleware service layers
with one exception. Security is a major topic in its own right, and we make the
assumption that SESA adopts the security mechanisms of the underlying technolo-
gies on which it builds (Web service and message-based systems). We are primarily
interested in the broker and base services as they provide the novel aspects of the
middleware.

9.2.2.2 Broker Services

Service Discovery The discovery service is concerned with ﬁnding Web ser-
vice descriptions that match the goal speciﬁed by the service requester. A ser-
vice requester provides the WSMO description of a goal to be achieved (de-
scribed in terms of the desired capability with preconditions, assumptions, ef-
fects, and postconditions). This is matched against WSMO descriptions of Web
services available to the discovery service as the level of description between
goals and Web Services will naturally vary and because it is impractical for ser-
vice descriptions to include all possible information on the functionality they pro-
vide.

Various discovery approaches have been developed and implemented as part of
the WSMX prototype for SESA. The theoretical foundation for service discovery
developed in [8, 14] clariﬁes a number of conceptual issues related to service dis-
covery. It proposes a distinction between service discovery and Web service dis-
covery and identiﬁes three major steps in service discovery, following the idea of

1http://www.iso-architecture.org/ieee-1471/.

9.2 Technical Solution

Table 9.1 Discovery service interface

Aspect

Detailed information

177

Description

Provided To

Provides access to the Semantic Web Service discovery mechanism of SESA based
on the conceptual model provided by WSMO

The Core service which has the responsibility of managing the life cycle of in-
stances of Execution Semantics, and it may therefore need to invoke the Discovery
Service. Processes on SESA are executed as instances of Execution Semantics.
Additionally, the Orchestration Engine service may also need to make invocations
to the Discovery service (see Sect.Sect. 9.2.2.2)

Inputs

A WSMO Goal and, optionally, input data speciﬁed as instances of concepts from
one or more WSMO ontologies

Outputs

A list of unordered WSMO Web service descriptions

heuristic classiﬁcation that has been identiﬁed in [3]. In this approach, a problem
is ﬁrst lifted to a more abstract level, then matching of abstract entities (requests
and services) is performed, and ﬁnally the candidate set is reﬁned with respect to
concrete data.

The interface provided by the discovery service is described in Table 9.1.

Service Ranking The ranking service provides a means to identify the best ser-
vices given a set of services functional compatible with the user’s request. It pro-
duces an ordered list of services according to user’s preferences and non-functional
properties criteria like price, availability, etc. Once a ranked list of Web services that
can fulﬁll the user’s concrete goal is prepared, SESA or the user must then choose
which of the services to invoke.

Our approach for ranking and selection [22] is a multi-criteria ranking approach
based on evaluation of non-functional properties. Non-functional properties spec-
iﬁed in goal and service descriptions are formalized in a semantic language (i.e.,
WSML) by means of logical rules using terms from NFP ontologies. The logical
rules used to model NFPs of services are evaluated during the ranking process by a
reasoning engine. Additional data is required during this process: (i) in which NFPs
the user is interested, (ii) the importance of each of these NFPs, (iii) how the list of
services should be ordered (i.e., ascending or descending), and (iv) concrete instance
data extracted from the goal description. The non-functional properties values ob-
tained by evaluating the logical rules are sorted and the order list of services is built.
The corresponding ranking interface is described in Table 9.2.

Data Mediation Every time data is exchanged as messages between services,
the owner of each service must be conﬁdent that they will be able to correctly
interpret the data types used in the messages and that all parties engaged in the
message exchange share a common understanding of the meaning of those data
types.

In the SESA architecture, the Data Mediation service has the role of reconcil-
ing data heterogeneity problems that might appear during discovery, composition,

178

9 The Web Service Execution Environment

Table 9.2 Ranking service interface

Aspect

Detailed information

Description

Provided To

Inputs

Outputs

Provides access to the ranking mechanism that takes into account non-functional
properties descriptions

Ranking may be called by the Core service, after Discovery has been invoked, as
part of the execution of an instance of Execution Semantics

A WSMO goal including non-functional properties, preferences over these prop-
erties and input data

A list of WSMO Web service descriptions, ordered based on the values of the non-
functional properties speciﬁed by the requester in the goal description

Table 9.3 Data mediation interface

Aspect

Detailed information

Description

Applies mapping rules between ontologies on instances of the source ontology to
create instances of the target ontology

Provided To Data mediation may be required during service discovery, orchestration and as an

essential part of process mediation

Inputs

Outputs

IRIs identifying the source and target ontologies, and a set of instances of concepts
from the source ontology

A set of instances of concepts from the target ontology corresponding to the input
source ontology instances. The relationship between the input and output instances
is deﬁned by mapping rules

selection or invocation of Web services. This service uses the inter-ontology map-
pings described in a declarative mapping language, such as that deﬁned in [15].
This facilitates scalability, as a single logical service can provide all data medi-
ation requirements, independent by the number of ontologies that must be medi-
ated. Naturally, at run-time this service depends on the availability of the map-
pings. The creation of such mappings requires the involvement of domain ex-
perts supported by the availability of mapping tools such as the one provided
in WSMT.

Two aspects of these mappings need to be taken into account in the design of
the Data Mediation service. The Data Mediation service needs to have access to a
persistent repository in which the mappings are stored. In addition, as the mappings
are not tied to a formal language, they require grounding to such a language before
they can be used. Once grounded, the mappings can be used by a reasoner to gen-
erate instances of a target ontology based on instances of the source ontology. This
implies a dependency from the Data Mediation service to the Logical Reasoner ser-
vice. There is a single interface for the data mediation service and this is shown in
Table 9.3.

9.2 Technical Solution

179

Choreography Engine
In WSMO, choreography interface descriptions deﬁne
both the messages that an entity expects to send and receive, and the control ﬂow
between those messages. Choreography interfaces belonging to Web services are
related to how the overall capability of the service can be achieved while those be-
longing to goals are related to how the supplier of the goal wishes to interact with
a service in order to invoke its capability. For example, a Web service selling IBM
notebook computers may use the RosettaNet PIP3A42 protocol to specify that it
expects to send and receive the following messages in this order:
• Receive a purchase order (PO) message.
• Send a purchase order acknowledgment message (POA).
• Send a purchase order conformation message (POC).
• Receive a purchase order conformation acknowledgment message (POCA).

This message exchange can be considered as a deﬁnition of a business process
to achieve a given capability. It does not care whether a service with that capability
is designed to implement all its functionality by itself, or if it uses other services to
do so. What the choreography interface is explicitly stating is that the only way to
obtain the service functionality is through the exchange of the speciﬁed messages in
the speciﬁed order. WSMO choreography interfaces are deﬁned using ontologized
abstract state machines. In essence, each time a goal and Web service are deter-
mined to match each other, an instance of each of their choreographies must be
created and the ﬂow of messages through those choreography interfaces handled.
The Choreography Engine is responsible for this task.

As abstract state machines, choreography interfaces consist of a universe (the
kinds of data available to the choreography) and a set of rules (conditional, update,
block-parallel) that operate on instances of data from the universe. The Choreog-
raphy Engine service for SESA has to be able to handle these descriptions where
the universe is represented by the State Signature, in terms of WSMO ontologies,
and the rules are speciﬁed using logical expressions written in terms of the WSML
variant being used.

The engine works as follows. First, choreography interface instances for the goal
and Web service are created. Each has an associated knowledge base to which in-
stances of ontological concepts can be added. After each change to either knowledge
base, the conditions in the headers of the respective sets of rules are examined to see
if any of the rules ﬁre. The ﬁring of a rule may result in data being either sent to or
from the goal or Web service owning that choreography interface. The interface for
the choreography engine is described in Table 9.4.

Orchestration Engine
In WSMO, each Web service may achieve its functionality
through a composition of other Web services. This is described as the orchestration
of the Web service and resembles a process deﬁnition. Each step in the orchestra-
tion can be represented as a WSMO goal or Web service description. Describing a
process in terms of goals to be achieved at each step greatly adds ﬂexibility as the

2http://www.rosettanet.org/.

180

9 The Web Service Execution Environment

Table 9.4 Choreography engine interface

Aspect

Detailed information

Description

Allows registration and state-update operations. Registration involves telling the
engine to create an instance of a choreography interface (and associated knowl-
edge base) in its internal memory. This may be a new or pre-existing choreography
interface. The latter is the case for long running interactions whose state should
be stored in persistent storage and re-loaded when new messages for that chore-
ography instance arrive. Updating the state means providing the instance of the
choreography interface with data needed by the control ﬂow it speciﬁes. Rules are
run over the provided data and may result in the invocation of a service

Provided To

The choreography engine can be invoked directly after discovery if there is no data
or process mediation required. Otherwise, it is expected that the Process Mediation
service creates the messages that this service receives

Inputs

A set of ontological instances corresponding to a subset of the concepts deﬁned in
the state signature of the choreography

Outputs

No value is returned

binding of goals to services can be deferred to execution time and handled by the
execution environment.

Although it may seem counterintuitive to provide internal details of how a service
is composed in the service description itself, this can prove to be very useful in
environments where dynamic service composition is a requirement or where the
software process is stable, but the providers of steps in the process may change.
For example, a Web portal for a telecom broker may allow a customer to create
a request for a product bundle including broadband, landline and provisioning for
a Web site. The broker has access to multiple service providers for each product
and wants to defer the choice of the best set of providers for each bundle request
until run-time. The customer request is written as a goal and matched against a Web
service with an orchestration having three steps (one for each product being ordered)
each represented by a WSMO goal. Using goals means that the broker retains the
ﬂexibility of allowing each goal to be bound to the most suitable service at run-time
when the service is needed. This is in contrast to hard-wiring a business process to
speciﬁc services when the process is designed.

As with any other form of integration, each Goal in a composition described
by an orchestration may have its own information model. This mirrors a common
situation in workﬂows where the data ﬂow aspect can only be deﬁned across het-
erogeneous data models through the use of data transformations. These data trans-
formations often operate on the structure rather than the semantics of the data. We
have already described how the data mediation service overcomes data heterogene-
ity through mappings between ontological concepts. This more generic and ﬂexible
approach can be applied to data ﬂow between steps in a service orchestration. Data
mediation in this context can be explicitly or implicitly declared. Implicit means
that when the orchestration description is created, speciﬁc data mediation steps are
introduced to the orchestration description. Explicit means that the engine execut-
ing the orchestration description has sufﬁcient information available at run-time to

9.2 Technical Solution

181

Table 9.5 Orchestration engine interface

Aspect

Detailed information

Description

An instance of an orchestration must be registered to the engine before it can be
used. The registration operation creates an orchestration instance and its associated
knowledge base. The ontologies used by the orchestration may be imported to the
knowledge base at this point or later, e.g., when the ﬁrst message for the orchestra-
tion arrives. A second operation of the interface called updateState is required to
allow new data to be made available to the orchestration instance so that its state
can be updated

Provided To

The orchestration engine is accessed by the Core of SESA which executes the
abstract descriptions of the various supported execution semantics We describe the
Core in Sect. 9.2.2.3

Inputs

Outputs

The initialization of the orchestration requires the identiﬁer (IRI) of the Web ser-
vice description containing the orchestration

The registration returns an identiﬁer to the instance of the orchestration. The update
state operation does not return any value

determine if (i) mediation is required and (ii) if a mapping between the source and
target ontologies is available to be executed.

Assuming that suitable mappings exist between the two ontologies, the orches-
tration engine ﬁnds and applies them on-the-ﬂy at run-time. This is because an or-
chestration is essentially a composition of choreographies where the output of the
choreography of a goal (or service) at one step provides input for the choreography
of another step. Where a data mismatch occurs, the orchestration engine can ex-
amine the corresponding choreographies to determine the ontologies used and the
associated mappings (see Sect. 9.2.2.2) and apply these mappings to the instance of
the concept to be transformed.

In this way, it may prove more effective to carry out this work when the or-
chestration is being composed. Explicit calls to the Data Mediation service can be
incorporated into the orchestration description as required. Table 9.5 describes the
interface of the Orchestration Engine.

9.2.2.3 Base Services

The base services represent functional services fundamental to the infrastructure of
the SESA system. They are described in the following sections in terms of their
functionality and interfaces.

Core The SESA architecture essentially supports distribution as each part of its
functionality is provided as a service that can be designed and implemented in a dis-
tributed system. A coordinating service (the Core) takes the responsibility for pro-
viding a messaging infrastructure and for managing administrative tasks such as the
loading of services and fault monitoring. Service loading can either occur through a
deﬁned list when the Core is started (bootstrapping) or on-the-ﬂy (hot-deployment).

182

9 The Web Service Execution Environment

Table 9.6 Core: ManageSystem interface

Aspect

Detailed information

Description

In this design, the Core provides the microkernel for the SESA system. It must be
explicitly started and stopped, it must be possible to add and remove services while
the system is running, and it should be possible to extract information on the health
of the system as a whole

Provided To

The operations provided by this interface are aimed at system administrators and
would most likely be best presented through a graphical user interface dashboard
type of application

Inputs

Outputs

Starting takes no input. Stopping takes an identiﬁer of the system. Monitoring re-
quires the system identiﬁer and identiﬁers of one or more monitoring types on
which information should be gathered

Starting returns an identiﬁer for the started system. Stopping and service manage-
ment have no explicit functional return information aside from possible conﬁrma-
tion messages. Monitoring returns information regarding the health and throughput
of services as well as information about the system as a whole

It is important to note that the only functional restriction on the location of services
with respect to the Core is that they can be identiﬁed using Web identiﬁers and
reachable through the chosen messaging implementation. For example, a shared tu-
ple space would mean that services could be located on any physical machine or
network that has access to that shared space (see Chap. 10).

The messaging infrastructure must be transparent to the other services in the ar-
chitecture, thus enabling strong decoupling. To achieve this transparency, the load-
ing and hot-deployment of the services must take care of adding whatever deploy-
ment code is necessary to the services. One possible technique for this is the use of
deployment conﬁguration ﬁles and wrappers. The Core is responsible for handling
three main functional requirements:
• A framework for management including monitoring, and starting and stopping

the system.

• Facilitating communication between services. Messages must be accepted and
routed to a suitable target service, enabling the communication and coordination
of services.

• Support for the life cycle of Execution Semantics. Execution Semantics specify
the process-types that are available to run on the SESA architecture. They enable
the separation between the deﬁnition of what the architecture does from how it
achieves. Multiple deﬁnitions of Execution Semantics are supported and multiple
instances of each Execution Semantics may run concurrently.

There are three interfaces for the Core. These are ManageSystem, Messaging and

ExecutionSemantics, shown in Tables 9.6, 9.7, and 9.8, respectively.

External Communications Manager While the Core provides the infrastructure
for messaging between the various services that make up the SESA middleware,
there is also a need to interact with services and entities that are external to SESA.

9.2 Technical Solution

Table 9.7 Core: Messaging interface

Aspect

Detailed information

183

Description

The Core provides the functionality of a message bus accepting messages repre-
sented as events and routing each of them to a target service that has subscribed
to that event. The routing takes place in the context of a particular instance of an
Execution Semantics

Provided To All services in the architecture participate in the messaging mechanism but this
should be transparent to them. The transparency should be made possible by the
addition of whatever additional code is necessary at the time the service is deployed
to the SESA system, using a service deployment descriptor (typically, an XML
ﬁle). It is this additional code that interacts with the messaging system, isolating it
from the service. The service should only be invoked by its deﬁned interface

Inputs

Subscription requires the speciﬁcation of an event type for the message and an
identiﬁer for the service instance. Sending a message must specify the message
type and the instance of the Execution Semantics to which it belongs. Receiving a
message means that the Core must be able to push a message to services that have
subscribed to that particular message type. Another possibility that does not re-
quire subscription is to use a pull method where services check the Core at regular
intervals to see if any message of a suitable type is available. Either way, the tar-
get service must receive the message and the instance of the Execution Semantics
specifying the context in which it was sent

Outputs

In terms of the logical functionality, there is no explicit output

Table 9.8 Core: Execution Semantics interface

Aspect

Detailed information

Description

Provided To

Inputs

Outputs

Execution Semantics is the name given to the process deﬁnitions that the SESA
architecture can support. It separates the description of the process from its imple-
mentation

SESA provides an external interface that allows for a service requester to request
that a Goal be achieved or that a speciﬁc service be invoked. This interface is
attached to the Communication Manager service. Each such user request results
in the creation of an instance of a suitable Execution Semantics to deal with the
request. Once an instance of an Execution Semantics exists, it is driven by the
receipt of events representing messages from speciﬁc services. For example, in the
Execution Semantics description for the AchieveGoal process, once the Execution
Semantics receives an event indicating that the Discovery Service has completed
successfully, it will raise an event for Process Mediation to take place

Creation of an instance of Execution Semantics requires the identiﬁer of the corre-
sponding type. Updating an instance of an Execution Semantics requires its iden-
tiﬁer and an event indicating the outcome of some services functionality

Starting an execution semantics returns an identiﬁer. Receiving an event requires
the event identiﬁer and the identiﬁer for the instance of the Execution Semantics
(assuming that these identiﬁer point to the complete data in persistent storage)

This is the role of the External Communications Manager service (ECM). The ser-
vice should be open to supporting as many transport and messaging protocols as
possible and this support should be transparent to SESA.

184

9 The Web Service Execution Environment

Table 9.9 ECM: Invoker interface

Aspect

Detailed information

Description

The ECM Invoker handles all invocations from the SESA architecture to external
services. It is responsible for carrying out any necessary transformations and if
security or encryption is required, it should coordinate any associated tasks

Provided To

The Choreography Engine service (see Sect. 9.2.2.2) is responsible for raising
events that lead to the Invoker interface being called

Inputs

Outputs

The identiﬁer of the service being invoked, the list of WSML instances to be sent
and the identiﬁer of the grounding that identiﬁes the exact operation and endpoint
for the invocation

The invocation of a service is treated as asynchronous from the perspective of
the Choreography Engine raising the invocation event. In actual fact, the wrapper
attached to the ECM at deployment times shields the Choreography Engine from
needing to know about this. If the Web service invocation is synchronous, then the
wrapper should use an individual thread to wait until the Web service response is
returned and then raise a suitable event to be passed to the messaging mechanism
of the Core. Where the Web service invocation is synchronous, there is no return
data immediately associated with the invocation. Rather the service must make a
subsequent callback to an endpoint on the SESA architecture if it has data to return

The link between the semantic description of a service and the concrete speciﬁ-
cation of the service’s endpoints and operations (e.g., provided by WSDL) is deﬁned
by the grounding. When a service is about to be invoked, the ECM service must be
able to manage any transformations necessary in terms of data representation and/or
communication protocols. For example, typically Web Services expect to receive
SOAP messages over HTTP with the SOAP payload represented in XML conform-
ing to a speciﬁed XML Schema deﬁnition. As the internal representation of data
within SESA is in terms of WSMO, the data must be lowered from a rich semantic
language to the structure syntax of XML.

Communication must also be supported in the opposite direction, i.e., from a
service requester to SESA. Continuing the last example of a Web service using
SOAP over HTTP with XML content, messages must be lifted to WSML before
they can be further processed by the services making up SESA. Although, currently
very popular, the combination of SOAP, HTTP and XML are not guaranteed to be
the only message, transport and data speciﬁcations used by external services. Many
other valid combinations are possible and, where practical, should be supported by
the ECM. There are two interfaces deﬁned for the ECM service: Invoker described
in Table 9.9 and Receiver in Table 9.10.

Parser The information model for the content of all messages passed between the
SESA services (e.g., Discovery, Selection, Mediation, etc.) is deﬁned by the WSMO
metamodel. The language used to represent the content and deﬁne the semantics of
these messages is WSML. However, WSML in its native state is not easily consum-
able by the implementation of the individual services. It is useful to be able to parse
WSML into a form that is more suitable for application programming. Such a form

9.2 Technical Solution

Table 9.10 ECM: Receiver interface

Aspect

Detailed information

185

Description

The ECM Receiver handles all incoming messages from external entities. There
are two categories of messages. The ﬁrst are from SESA users who wish to run
one of the processes deﬁned by the deﬁnitions of Execution Semantics provided
for SESA. These include service discovery, Goal achievement and speciﬁc Web
Service invocation. The second category is for messages that are sent to SESA
from a service as part of an already on-going conversation, e.g., the asynchronous
response to a Web service operation mentioned in the description of the Invoker
interface

Provided To

External entities using SESA for particular tasks

Inputs

Outputs

When achieving a Goal, the Goal description or an IRI that resolves to the Goal
description along with WSML instance data to act as input must be provided. The
inputs for executing a Web service are almost the same, with Web service descrip-
tion required in place of the Goal description. For discovery, the Goal identiﬁer is
needed along with optional ontological instance to restrict the set of valid discov-
ered services

Achieving a Goal may result in output WSML data being returned to the external
requester. Likewise, the execution of a speciﬁc service. For discovery, a possibly
empty set of Web service descriptions is returned

is provided by WSMO4J [23], an API and reference implementation for WSMO
using Java.

WSMO4J is a convenient programming abstraction for WSMO semantic descrip-
tions. However, it is not a prerequisite. Likewise, the parser functionality is only
required if the SESA design cannot natively work with WSML at the interfaces of
each component. For descriptive purposes and convenience, we make the assump-
tion that WSMO4J is used in SESA for the remainder of this chapter.

When and where parsing takes place is a design and implementation issue. In de-
signs where the services are implemented in Java and hosted on a common Java
virtual machine (JVM), or on multiple JVMs that can exchange objects, it may
make sense to parse WSML messages as soon as they arrive at the Receiver in-
terface and then use the internal WSMO4J model as the internal SESA representa-
tion. Where services are designed as standalone Web Services, it may makes sense
to exchange messages between SESA services in WSML and allow each service
to carry out WSML parsing as they require. Table 9.11 describes the Parser inter-
face.

Reasoner To increase the level of automation for processes performed in dis-
tributed systems following the Service-Oriented Architecture principles, SESA pro-
poses a solution based on semantic descriptions of the entities involved in the use of
Web services as a technology for application and system integration. Such seman-
tic descriptions are processed and understood by a reasoning engine that is able to
answer questions. The reasoning engine or services provides a basic functionality
that is required other SESA services. Discovery, Data Mediation and Process Me-

186

9 The Web Service Execution Environment

Table 9.11 Parser interface

Aspect

Detailed information

Description

The Parser transforms WSML descriptions into the Java object model provided by
WSMO4J

Provided To Accessible by any of the SESA services that wish to use WSMO4J as their internal

Inputs

Outputs

object model

A WSML document

A set of WSMO4J objects

Table 9.12 Reasoner interface

Aspect

Detailed information

Description

The reasoner enables queries that may require logical inferencing to be made over
a knowledge base deﬁned by ontologies using a deﬁned formal logic model, e.g.,
Description Logics (DL)

Provided To Accessible by any of the SESA services but is required by Discovery, Data and
Process Mediation. It is also required by the algorithms deﬁned in this chapter for
the Choreography and Orchestration engines

Inputs

Outputs

One or more ontologies must be available to the reasoning engine to establish its
knowledge base. Queries to the engine take the form of logical expressions

A possibly empty set of identiﬁers that provide an answer to each query put to the
Reasoner

diation services rely on the logical reasoning. For service discovery, the reasoner
must determine if the capability of a Goal can be matched by the capability of one
or more Web services, also expressed as logical expressions. This requires a reason-
ing engine that answers queries on the basis of the underlying formal logic model
used by the semantic language. It is desirable that the Reasoning Engine interface
be provided either through Java, supporting WSMO4J, or as a Web service that ac-
cepts and returns WSML expressions. The interface for the Reasoner is described in
Table 9.12.

Resource Manager The Resource Manager Service provides access to persistent
storage for the SESA architecture. Persistence at the system level is required for all
WSMO entities used during the operation of the WSMX system as well as the non-
WSMO entities, e.g., those representing messages and their states used during the
execution of processes provided by the architecture (through execution semantics).
There are two interfaces deﬁned for the Resource Manager: WSMO Repository in
Table 9.13 and Non-WSMO Repository in Table 9.14.

9.2 Technical Solution

187

Table 9.13 WSMO repository interface

Aspect

Detailed information

Description

This provides retrieval, add, update, remove (and possibly archive) operations on
a repository of WSMO descriptions for Web services, Goals, Ontologies and Me-
diators

Provided To Accessible by any of the SESA services

Inputs

Outputs

When adding or updating a WSMO element, a valid WSML description or cor-
responding set of WSMO4J Java objects is required. When removing, the iden-
tiﬁer(s) for the element(s) to be removed must be provided. Individual WSMO
elements can be retrieved by specifying their unique identiﬁer while it should be
possible to retrieve all WSMO descriptions of a particular type, i.e., Web service
or Goal or Mediator or Ontology

When adding, updating, or removing there is no speciﬁc output beyond possible
conﬁrmation messages. When retrieving a WSML document containing all the
requested elements or a corresponding set of WSMO4J objects should be returned

Table 9.14 Non-WSMO repository interface

Aspect

Detailed information

Description

There are many aspects of the operation of the SESA architecture that require per-
sistent storage. One example is that instances the Choreography Engine service
should remain stateless, storing and retrieving instances of choreographies as re-
quired based on unique identiﬁers for those instances. Another example is that the
architecture should keep track of the life cycle of events, representing messages
between services in the context of an instance of an Execution Semantics. This is
important for monitoring the health of the system and for maintaining historical
information for performance monitoring over time

Provided To Accessible by any of the SESA services. Ideally, this service takes advantage of
an object-relational mapping framework like Hibernate that abstracts the details of
the persistence from the application developer

Inputs

Outputs

Depends on the SESA service

Also depends on the SESA service

9.2.2.4 Technology Viewpoint

In this section, we provide some details on the technology used in the design for the
Core component of the Web Services Execution Environment (WSMX),3 an open-
source prototype of the SESA architecture. The purpose is to provide some insight
into the challenges of creating a software design that realizes the SESA architecture.

Core Design The Core component coordinates the other components of the archi-
tecture. It manages the interaction between the other components through the ex-
change of messages containing instances of WSMO concepts expressed in WSML,

3http://sourceforge.net/projects/wsmx.

188

Fig. 9.4 Component
management in the
architecture core

9 The Web Service Execution Environment

and provides the microkernel and messaging infrastructure for the architecture. This
component is responsible for handling three main functional requirements:
• A framework for the management and monitoring the start and stop of the system

as well as its health.

• The Core facilitating the communication between components; it accepts mes-
sages and routes them to a suitable target component, enabling communication
and coordination of components.

• Supporting the life cycle of Execution Semantics (declarative deﬁnitions of the
allowed operational behavior of the architecture). Multiple deﬁnitions of execu-
tion semantics are supported and multiple instances of each execution semantics
may run concurrently.

The WSMX prototype of the Core component is realized as a microkernel utiliz-

ing Java Management Extensions (JMX) and is described in detail in [12].

Management Managing system components is a critical issue for the healthy
functioning of any system. The very process of making management explicit, cap-
tures an invariant that helps to leverage the support for dynamic change of the rest
of the system. Figure 9.4 presents an overview of the infrastructure provided by
the Core to its components, which allows the management and monitoring of the
system.

The Core offers several dedicated services, the most essential of which is per-
haps the bootstrap service responsible for loading and conﬁguring the application
components. The Core also employs self-management techniques such as sched-
uled operations, and allows administration through a representation independent

9.2 Technical Solution

189

Fig. 9.5 Communication and coordination in the architecture core

management and monitoring interface that allows for a number of different man-
agement consoles serving different purposes. Text-Terminal-, Web-Browser- and
Eclipse-Framework-based consoles have been implemented.

As is common with middleware and application servers, the Core hosts a num-
ber of subsystems that provide services to components and enable inter-component
communication. Pool management takes care of handling several component in-
stances and subsystems. The Core is in the unique position of offering services to
the individual components, such as logging services, transport services and life cy-
cle services.

One of the principles underlying the architecture design is support for distribu-
tion. The design of the Core allows for transparent distribution of middleware ser-
vices in two ways. Firstly, the use of a shared virtual message space allows services
to be physically located on different servers. Secondly, it is possible for multiple
WSMX implementations to be conﬁgured as a federation, where if a middleware
service is not available at one site, the Core at that location can send a message to
another WSMX requesting the middleware service at that remote site.

Communication and Coordination The architecture avoids hard-wired bindings
between components—communication is based on events. Whenever a middleware
service is required, an event representing a request for that service is created and
published. Any services subscribed to the event type can fetch and process the event.
The event-based approach naturally allows asynchronous communication. As illus-
trated in Fig. 9.5 events exchange is conducted using a shared Tuple Space (orig-
inally demonstrated in Linda [9]; see Chap. 10 for more details) which provides
persistent shared space enabling interaction between parties without direct event
exchange between them.

190

9 The Web Service Execution Environment

The Tuple Space enables communication between distributed units running on
remote machines or on the local machine. It should be emphasized that the func-
tional components themselves (discovery, mediation, etc.) are completely unaware
of this distribution. That is, an additional layer provides them with a mechanism of
communication with other components that shields them from the actual mechanism
of transport which can be local or remote.

Through the infrastructure provided by the Core, component implementations
are separated from communication issues. This infrastructure is made available to
each component implementation during instantiation of the component carried out
by the Core during a bootstrap process. This is the process that occurs when a com-
ponent is identiﬁed and loaded by the WSMX prototype. Through the use of JMX
and reﬂection technology, this can occur both at start-up as well as after the sys-
tem is up and running. In particular, the communication infrastructure carries the
responsibility to interact with the transport layer (a Tuple Space instance).

To enable one middleware service request functionality of another, a proxy mech-
anism is utilized. The calling service asks the WSMX Core for a proxy to the other
middleware service it wishes to invoke. Once provided, the proxy can be used as if
it were a direct interface to the required service. In fact, the proxy is implemented to
publish an event with a type targeted at the required service and returns any results
to the calling service.

Each middleware service uses conﬁguration metadata which allows the Core to
select the service and generate wrappers for it as it is deployed. Figure 9.6 shows
a process represented by an Execution Semantic including the middleware services
and associated wrappers. The wrappers are generated and managed by the Core to
separate middleware services from the transport layer for events. One wrapper raises
an event with some message content and another wrapper can at some point in time
consume this event and react to it.

Wrappers are generic software units that separate the implementation of WSMX
components from the communication mechanism. They provide methods to compo-
nents, enabling communication with other components. Wrappers are automatically
generated and attached to each component during instantiation. This is carried out
by the WSMX Kernel. There are two major parts:
• Reviver Its responsibility is to interact with the transport layer (i.e., the Tuple
Space). Through the transport layer, the Reviver subscribes to a proper event-type
template. Similarly, the Reviver publishes result events in the Tuple Space. This
level of abstraction reduces the changes required to code if the transport layer
changes.

• Proxy A Proxy is utilized for one component to be able to request another’s func-
tionality. The calling component speciﬁes the component name, the method to
be invoked and the required parameters. The proxy creates the proper event for
this data and publishes it in the Tuple Space. A unique identiﬁer is assigned to
the outgoing event and is preserved in the response event. Proxies subscribe to
the response event by specifying a unique identiﬁer in the event template. This
guaranties that only the Proxy that published this event will receive the result
event.

9.2 Technical Solution

191

Fig. 9.6 Process, its wrappers and context

9.2.3 SESA Execution Semantics

The advent of SOA makes it more practical to separate the deﬁnition of how a sys-
tem operates from the implementation of the system itself. We deﬁne execution se-
mantics as formal descriptions of the operational behavior of the system (analogous
to business process descriptions in BPEL, but at the system level). By separating the
description of the system behavior from the system implementation, we can achieve
greater ﬂexibility of how the implementations of the SESA architecture can be used
and avoid rebuilding the system in the event of a new or changed requirement of
how the system should operate. In terms of the behavior of the architecture, we in-
troduced two types of services: middleware services and business services. Middle-
ware services provide the functional services required by SESA to operate. Business
services are exposed by information systems external to the SESA and the role of
the SESA platform is to coordinate interoperation between them. The execution se-
mantics are deﬁned as middleware services describing in a formal and unambiguous
way how the system built of loosely-coupled middleware services operates.

This chapter describes the execution semantics which should be supported by
SESA. We present three fundamental scenarios (using UML activity diagrams).
We envision new, dynamically created execution semantics reﬂecting changing busi-

192

9 The Web Service Execution Environment

ness needs where middleware services can be composed in the ﬂexible way accord-
ing to the principles of SOA. We provide an example which shows how execution
semantics operating on middleware services can be used in practice. We also look
at the execution semantics from WSMX technical perspective.

9.2.3.1 Motivation

The speciﬁcation of system behavior can be viewed as the data and control ﬂow
between system components (services in SOA), where the actual actions take place.
System designers tend to create architectures for speciﬁc needs that often result in
rigid system behavior difﬁcult to adapt to changing requirements. In SESA, mid-
dleware services that makes up the system building blocks can be used in various
scenarios some of which may not be known at design time. For instance, one execu-
tion semantics may specify Goal-based discovery of Semantic Web Services, while
another may deﬁne Semantic Web service invocation. Both execution semantics are
deﬁned explicitly using the same middleware services, but with different data and
controls ﬂows. Middleware services cooperate with each other at the interface level
but they do not refer to each others implementation directly.

A software design process should result in a design that is both an adequate
response to the user’s requirements and an unambiguous model for the developers
who will build actual software. A design therefore serves two purposes: to guide
the builder in the work of building the system and to certify that what will be built
will satisfy the user’s requirements. We deﬁne execution semantics, or operational
semantics, as the formal deﬁnition of system behavior in terms of computational
steps. As such, it describes in a formal, unambiguous language how the system
operates. Since, in a concurrent and distributed environment, the meaning of the
system to the outside world consists of its interactive behavior, this formal deﬁnition
is called execution semantics.

The following lists major advantages of specifying system behavior by execution

semantics over informal methods are the following:
• Foundations for model testing It is highly desirable to perform simulation of
the model before the actual system is created and enacted. It allows one to detect
anomalies like deadlock, livelock or tasks that are never reached. However, as
pointed out by Dijkstra in [6], model simulation allows pointing out the presence
of errors, but not the lack of them. Nevertheless, it is paramount to detect at least
some of system malfunctions during design time rather than during the run-time.
Therefore, semantics of utilized notations have to be perfectly sound in order to
create tools enabling simulation of created models. Only formal, mathematical
foundations can meet these requirements.

• Executable representation Similarly, as in the case of model testing, using for-
mal methods provides a sound foundation for building an engine able to execute
created models. Such an engine would not necessarily need to be able to detect
livelock and other model faults. This fact distinguishes this bullet from the previ-
ous one.

9.2 Technical Solution

193

• Improved model understanding among humans Soundness of the utilized

method improves the comprehensiveness of the model.

Several methods exist to model software behavior. Some of them model sys-
tem behavior in a general way (like UML diagrams), others impose more formal
requirements on models (for instance, Petri net-based methods, process algebra,
modal and temporal logics, and type theory). These methods have different char-
acteristics: some are more expressive than others; some are more suited for a certain
problem domain than others. Some methods provide graphical notation like UML
or Petri nets, some are based on syntactic terms like process calculi and logics; some
methods have tool support for modeling, veriﬁcation, simulation or automatic code
generation.

We impose two major requirements on the methodology utilized for modeling
fundamental SESA behavior. Firstly, it has to use a understandable and straightfor-
ward graphical notation. Secondly, it has to be unambiguous. These two require-
ments are met by UML Activity Diagrams which are familiar to the engineering
community and whose execution semantics can be disambiguated, for instance, in
the semantics speciﬁed by Eshuis [7].

9.2.3.2 Description Formalism

UML 2.0 (Uniﬁed Modeling Language) is a widely accepted and applied graphical
notation in software modeling. It consists of a set of diagrams for system design,
capturing two major aspects, namely static and dynamic system properties. Static
aspects specify system structure, its entities (objects or components) and dependen-
cies between them. These structural and relational aspects are modeled by diagrams
like Class Diagrams, Component Diagrams and Deployment Diagrams. Dynamic
aspects of the system are constituted by control and data ﬂow within the entities,
speciﬁed as Sequence Diagrams, State Machine Diagrams and Activity Diagrams.
Originally, UML was created for modeling aspects of object-oriented programming
(OOP). However, it has to be emphasized that UML is not only restricted to the
usage in OOP area, but is also applied in other ﬁelds such as Business Process Mod-
eling.

The primary goal of UML diagrams is to enable common comprehension of
structure and behavior of modeled software among involved parties (e.g., design-
ers, developers, other stakeholders, etc.). To the detriment of UML notation, this
information is conveyed in an informal way that may lead to ambiguities in certain
cases as pointed out in [11]. Since we want to model the behavior of SESA in a
widely used and understood manner, UML is the natural choice.

UML Activity Diagrams depict a coordinated set of activities that capture the
behavior of a modeled system. They are used to specify control and data ﬂow be-
tween the entities providing language constructs that enable it to model elaborate
cases like parallel execution of entities or ﬂow synchronization. For the SESA ar-
chitecture, they are used to identify the middleware services used in each speciﬁc
execution semantics along with the control and data ﬂow between them.

194

9 The Web Service Execution Environment

In each of the activity diagrams provided in this document, the actions that pro-
vide steps in the execution semantics are identiﬁed inside a red dashed-line box. The
middleware services for Discovery, Mediation, Selection, etc. are drawn as UML ac-
tivities with interfaces that accept inputs and provide output as data objects. These
interfaces are consistent with the deﬁned SESA middleware services. In each of
the provided activity diagrams, rounded rectangles with small square input pins de-
note actions. The pins represent input and output data ports. Rounded rectangles
with large rectangular boxes at their boundaries (e.g., Communication Manager in
Fig. 9.7) indicate activities that correspond to SESA middleware services. The rect-
angular boxes at the boundaries represent parameters that the activity accepts as
input or provides as output. Data ﬂow directional arrows can be identiﬁed as those
beginning or ending at a data pin or a parameter box. The actions inside the red
boundary are the responsibility of the execution semantics. Control ﬂow directional
arrows have no associated data and go from action to action inside the execution se-
mantics. Finally, the vertical thick black bars are data-ﬂow branches. Data ﬂowing
into a branch is made available at all outgoing ﬂows. Where multiple input pins are
available on an action, the action does not commence until data has arrived at each
of those pins. Data becomes available on all outgoing pins of an action, as soon as
that action is completed.

Due to the wide proliferation of UML notation several efforts were made to make
concrete its semantics, especially regarding the dynamic aspects of UML notation.
Semantics for UML Activity Diagrams, in the context of workﬂow modeling, was
speciﬁed in [7]. UML Activity Diagrams fulﬁll our requirements; therefore, they
are used as the graphical notation in this document, consistently with the semantics
given by Eshuis, to specify operational behavior of SESA.

9.2.3.3 Mandatory Execution Semantics

In the following subsections, we deﬁne three fundamental execution semantics iden-
tiﬁed for the SESA and describe the details of each. The SESA deﬁnes a set of
middleware services that are required to achieve the functionality of a Semantic
Web Services execution environment. Interfaces are deﬁned for each middleware
service, deﬁned in terms of the conceptual model provided by WSMO. The com-
bination of all interfaces provides the basis for the SESA application programming
interface (SESA API). Section 9.2.3.3 describes the scenario where Goal based ser-
vice discovery without service invocation is desired. Section 9.9 is an extension of
that described in Sect. 9.2.3.3—both service discovery and service invocation are
required. The client’s Goal and all data instances the client wishes to send to the
potential provided service are speciﬁed together as input. Section 9.2.3.3 describes
the situation in which clients already know the service they wish to invoke and have
the required data for this invocation available.

In each of the subsequent sections, execution semantics are linked to deﬁned en-
try points to the SESA architecture. Entry points can be considered as input ports, to
which messages can be sent, for initiating speciﬁc execution semantics. The follow-
ing notation is used (similar to the convention used by the JavaDoc documentation

9.2 Technical Solution

195

y
r
e
v
o
c
s
i
d
e
c
i
v
r
e
s

d
e
s
a
b
l
a
o
G

7
.
9

.
g
i
F

196

9 The Web Service Execution Environment

system), where execSemName stands for the name of the entry point to the system
for the execution semantics, input data types are the types of the input parameters re-
quired to start the execution semantics, and return data type is the data type returned
if the execution semantics completes successfully.

execSemName (Input data types): Return data type

We do not show Parser component in the following sections since we treat it as
a transformation component whose only role is to perform the transformation and
validation from the textual form of WSML to object-oriented representation which
can be more easily utilized by other SESA components.

Goal-based Web Service Discovery The following entry-point initiates this sys-
tem behavior:

getWebServices(WSMLDocument): Web services

A service requestor wishing to discover a list of Semantic Web services fulﬁlling its
requirements provides its requirements as a Goal description using WSML. A set of
WSML Web service descriptions whose capability matches the Goal is returned.

Figure 9.7 shows the activity diagram. A message containing a WSML Goal is
received and passed to the Communication Manager which takes care of whatever
message persistence that may be required. The Goal is sent to the Discovery activity
which looks for WSMO Web service descriptions with capabilities that match that
of the Goal. The discovery activity may need Data Mediation as part of its internal
design but this internal aspect of that activity is not modeled as part of this execution
semantics. Discovery continues until a set of matching Web services is compiled.
Assuming this set is non-empty, the selection activity determines which of the dis-
covered services to return to the service requester. The WSMO description of the
selected service must be transformed to WSML and packaged into a message that
can be sent back to the requester. The Communication Manager takes care of this
activity ending the execution semantics for Goal based discovery.

Web Service Invocation The following entry-point initiates this system behavior:

invokeWebService(WSMLDocument, Context): Context

where the service requester already knows which Semantic Web Service they wish
to invoke, the execution semantics illustrated in Fig. 9.8 is used. The ﬁrst input signal
provides the WSML content while the second provides a conversation context. If
this is the ﬁrst message being sent to the Web service, there will be no existing
conversation and this context signal will be empty. As in the other two scenarios,
the WSML input message is unpacked by the Communication Manager activity. In
this case, however, the WSML input contains both the target Web service description
and the input instance data.

After the WSML has been received, the WSMO Web service description and the
instance data are passed to the Data Mediation activity to handle any data mapping
that may be required (may require a WSML reasoner to be invoked internally).

9.2 Technical Solution

197

n
o
i
t
a
c
o
v
n
i

e
c
i
v
r
e
s

b
e
W

8
.
9

.
g
i
F

198

9 The Web Service Execution Environment

After that, Process Mediation has all input data at its input pins and can com-
mence. We do not describe the internal design of the Process Mediation activity
here but we do note that it is responsible for matching the message exchange pat-
terns required by the Goal and offered by the Semantic Web Service description.
This matching includes both the message patterns and the data types used by the re-
spective messages. Process mediation determines how the input data instances need
to be organized so that they can be understood by the Web service choreography
description. The output of Process Mediation is WSMO data instances organized in
this manner.

Once output from Process Mediation is available, the Choreography activity has
all required input and (most likely using a reasoning engine as part of its internal
design) determines which messages need to be sent out based on the choreography
description (an abstract state machine) of the Web service). This WSMO data must
be transformed into a format deﬁned by the Web service grounding information
(taken from the WSDL service binding) and sent to the Web service endpoint. This
activity is carried out by the Communication Manager.

Goal-based Service Execution The following entry-point initiates this system be-
havior:

achieveGoal(WSMLDocument): Context

A service requestor wishing to use SESA for all aspects of Goal based service in-
vocation (discovery, mediation, invocation) provides both the Goal and input data
descriptions in a single WSML document. A unique identiﬁer for the conversation
initiated by the receipt of the Goal is returned by the execution semantics to the
service requester. In parallel, the Goal and the WSML instance input data is pro-
cessed by the execution semantics to discover and invoke a service whose capability
matches that described by the Goal description.

This scenario illustrated in the UML activity diagram of Fig. 9.9 is based on
the assumption that the service requestor is able to provide, up-front, all input data
required by the discovered Web service.

The execution semantic is initiated by the receipt of the Goal and input data
messages. As in Fig. 9.7, the Communication Manager activity is used to unpack
the WSML content of the messages. Then the Discovery Execution Semantics com-
mences as described in Sect. 9.2.3.3, after which the Selection takes place complete,
the resulting Semantic Web Service is sent to the Web service Invocation Execution
Semantics as presented in Sect. 9.2.3.3.

Note that this execution semantic, without the discovery and selection activities,
could be used to handle messages returned from the Web service to be sent back
to the service requester, assuming that the service requester provided an invocable
endpoint at which it could receive such messages.

9.2 Technical Solution

199

n
o
i
t
u
c
e
x
e

e
c
i
v
r
e
s

d
e
s
a
b
l
a
o
G

9
.
9

.
g
i
F

200

9 The Web Service Execution Environment

9.3 Illustration by a Larger Example

In this section, we present a case scenario which tends to solve B2B integration is-
sues. Enterprise integration is an essential requirement for today’s successful busi-
ness. With the aim of overcoming heterogeneity, various technologies and standards
for the deﬁnition of languages, vocabularies and integration patterns are being de-
veloped. For example, RosettaNet deﬁnes standardized Partner Interface Processes
(PIPs) which include standard inter-company choreographies (e.g., PIP3A4 Request
Purchase Order (PO)) and the structure and semantics of business messages. Al-
though such standards certainly enable B2B integration, they still suffer from several
drawbacks. All partners must agree on using the same standard, and often the rigid
conﬁguration of standards makes them difﬁcult to adapt to local business needs.

The SESA architecture when applied to the B2B integration can help in resolving
interoperability problems between business partners and in maintaining the ﬂexible
and more reliable integration. In order to demonstrate the value of the SESA in the
B2B integration domain, we implemented a scenario from the SWS Challenge.4 The
SWS Challenge aims at establishing a common understanding, evaluation scheme,
and testbed to compare and classify various approaches to services integration in
terms of their abilities as well as shortcomings in real-world settings.

As Fig. 9.10 depicts, the scenario introduces various service providers (such as
Racer and Mueller) offering various purchasing and shipment options for various
products through the e-marketplace called Moon. On the other hand, there is a ser-
vice requester called Blue who intends to buy and ship a certain product for the best
possible price. The technology that the Moon operates on is the middleware system
enabling the SESA architecture. The following are the basic characteristics of the
scenario.
• Back-end systems Service requesters and providers use various back-end sys-
tems for handling interactions in their environment. For example, Mueller uses
Customer Relationship Management system (CRM) and Order Management Sys-
tem (OMS) while Blue uses a system based on the RosettaNet5 standard. Roset-
taNet is the B2B speciﬁcation deﬁning standard components called Partner Inter-
face Processes (PIPs) which include standard intercompany choreographies (e.g.,
PIP3A4 Purchase Order), and structure and semantics for business messages. Ser-
vice requesters and service providers maintain the integration with their back-end
systems through Web services (adapters for their back-end systems) while at the
same time they are responsible for their integration with the middleware through
semantic descriptions of services and/or through interfaces with the middleware.
• Modeling and publishing of semantic descriptions Engineers on the requester’s
and provider’s side model services and requests using the WSMO model and
publish them in the Moon middleware repositories. Engineers of the Moon de-
ﬁne mappings between different ontologies in repositories and store them in the
middleware.

4http://www.sws-challenge.org.
5RosettaNet (http://www.rosettanet.org).

9.3 Illustration by a Larger Example

201

e
l
p
m
a
x
e

g
n
i
n
n
u
R

0
1
.
9

.
g
i
F

202

9 The Web Service Execution Environment

• Interoperability issues Engineers on the requester’s and provider’s side model
services independently, meaning that they use different ontologies as well as dif-
ferent descriptions of choreographies. For example, the Blue models the request
and response messages according to the RosettaNet PIP3A4 Purchase Order (PO)
speciﬁcation while Mueller models the messages using proprietary information
and choreography speciﬁcations of the CRM/OMS systems. For a request mes-
sage sent by Blue, the Mueller must perform several interactions with the back-
end systems such as identify a customer in the CRM, open the order in the OMS,
add all items to be ordered to the OMS and close the order in the OMS.

The scenario runs as follows: All business partners ﬁrst model their business
services. After that, Blue sends the purchase order request captured in WSMO goal
to the middleware system which on reception of the goal executes the achieveGoal
execution semantics including: (i) discovery, (ii) selection, and (iii) orchestration.
During discovery, the matching is performed for the goal and potential services at
abstract level as well as instance levels (abstract-level discovery allows narrowing
down the number of possible Web services matching a given Goal while instance-
level discovery carries out detailed matchmaking considering instance data of the
service and the goal). During selection, the best service is selected (in our case
Mueller service) based on preferences provided by Blue as part of the WSMO goal
description. Finally, during orchestration, the execution and conversation of Blue
and Mueller services is performed by processing of choreographies’ descriptions
from the Blue’s goal and the Mueller’s service.

9.3.1 Modeling of Business Services

In this section, we show how Blue and Mueller systems can be modeled using
WSMO and WSML formalisms. The modeling phase involves following steps:
(i) Web Service Creation when underlying services as Web services with WSDL
descriptions are created, and (ii) Semantic Web Service and Goals Creation when
semantic service and goal descriptions are created using WSMO. For our scenario,
we create two services, namely PIP3A4 and CRM/OMS service (we model both
systems as one business service).
• Web Services Creation This step involves the creation of Web services as
adapters to existing systems, i.e., WSDL descriptions for these adapters including
XML schema for messages, as well as deﬁnitions of interfaces, their operations,
binding and endpoint. In our scenario, we use two adapters: (i) PIP3A4 adapter
and (i) CRM/OMS adapter. These adapters allow Mueller’s CRM and OMS sys-
tems to connect to the middleware, and perform lifting and lowering function-
ality for XML schema and ontologies according to the grounding deﬁnitions of
WSMO services.

• Semantic Web Services and Goals Creation In order to create Semantic Web
Services and Goals, the ontologies must be created (or reused) together with non-
functional, functional and interface description of services. In addition, a ground-
ing must be deﬁned from the semantic (WSMO) descriptions to the syntactic

9.3 Illustration by a Larger Example

203

(WSDL) descriptions. Semantic Web Services and Goals are described according
to WSMO Service and WSMO Goal deﬁnitions respectively. We create a WSMO
Goal as PIP3A4 service and WSMO Service as CRM/OMS service. Please note
that WSMO Goal and WSMO Service have the same structural deﬁnition, but
differ in what they represent. The difference is in the use of deﬁned capability
and interface—WSMO Goal describes a capability and an interface required by a
service requester whereas WSMO service describes a capability and an interface
provided by a service provider. In our scenario, this task is performed by domain
experts (ontology engineers) using WSMT. In this section, we further elaborate
on this step.

9.3.1.1 Creation of Ontologies and Grounding

One possible approach towards creation of ontologies would be to deﬁne and main-
tain one local domain ontology for Moon’s B2B integration. This approach would
further allow handling message level interoperability through the domain ontology
when lifting and lowering operations would be deﬁned from underlying message
schema to the domain ontology. Another option is the deﬁnition of independent on-
tologies by each partner and its systems. In our case, these are different ontologies
for RosettaNet and ontologies for CRM/OMS systems. The message level inter-
operability is then reached through mappings between used ontologies which are
deﬁned during design-time and executed during runtime. Although both approaches
have their advantages and limitations, we will use the latter approach in our sce-
nario. The main reason is to demonstrate mediators’ aspects to integration of ser-
vices which are available as independent and heterogeneous services.

We assume that all ontologies are not available up-front and they need to be
created by an ontology engineer. The engineer takes as a basis the existing stan-
dards and systems, namely RosettaNet PIP3A4 and CRM/OMS schema, and cre-
ates PIP3A4 and CRM/OMS ontologies, respectively. When creating ontologies, the
engineer describes the information semantically, i.e., with richer expressivity as op-
posed to the expressivity of underlying XML schema. In addition, the engineer cap-
tures the logic of getting from XML schema level to semantics introduced by ontolo-
gies by lifting and lowering rules executed on non-semantic XML schema and on-
tologies, respectively. These rules are part of grounding deﬁnition between WSMO
and WSDL descriptions and physically reside within adapters. In Listing 9.1, an ex-
ample of the lifting rules and the resulting WSML instance is shown for an extract
of a RosettaNet PIP3A4 message.

9.3.1.2 Creation of Functional and Non-Functional Descriptions

WSMO functional description (modeled as WSMO service capability) contains the
formal speciﬁcation of functionality that the service can provide, which is deﬁni-
tion of conditions on service “inputs” and “outputs” which must hold before and

204

(cid:2)
/∗ LiftingrulesfromXMLmessagetoWSML ∗/
...
instance PurchaseOrderUID memberOf por#purchaseOrder

9 The Web Service Execution Environment
(cid:3)

por#globalPurchaseOrderTypeCode hasValue "<xsl:value−of select="dict:

GlobalPurchaseOrderTypeCode"/>"

por#isDropShip hasValue

IsDropShipPo<xsl:for−each select="po:ProductLineItem">

por#productLineItem hasValue ProductLineItem<xsl:value−of select="position()"/>

</xsl : for −each>

<xsl: for −each select="core:requestedEvent">

por#requestedEvent hasValue RequestedEventPo

</xsl : for −each>
<xsl: for −each select="core:shipTo">
por#shipTo hasValue ShipToPo

</xsl : for −each>
<xsl: for −each select="core:totalAmount">

por#totalAmount hasValue TotalAmountPo

</xsl : for −each>

...

/∗ messageinWSMLaftertransformation ∗/
...
instance PurchaseOrderUID memberOf por#purchaseOrder

por#globalPurchaseOrderTypeCode hasValue "Packaged product"
por#isDropShip hasValue IsDropShipPo
por#productLineItem hasValue ProductLineItem1
por#productLineItem hasValue ProductLineItem2
por#requestedEvent hasValue RequestedEventPo
por#shipTo hasValue ShipToPo
por#totalAmount hasValue TotalAmountPo

...(cid:4)

Listing 9.1 Lifting from XML to WSML

(cid:5)

after the service execution, respectively. Functional description for our back-end
systems contains conditions that input purchase order data must be of speciﬁc type
and contain various information such as customer ID, items to be ordered, etc. (this
information is modeled as preconditions of the service). In addition, the service de-
ﬁnes its output as purchase order conﬁrmation as well as the fact that the order has
been dispatched. Functional description of service is used for discovery purposes in
order to ﬁnd a service which satisﬁes the user’s request. Non-functional properties
contain descriptive information about a service, such as author, version or informa-
tion about Service Level Agreements (SLA), Quality of Services (QoS), etc. In our
example, we use the non-functional properties to describe user preference for ser-
vice selection. In our case, the Blue company wants to buy and get shipped a product
for the cheapest possible price which is encoded in the WSMO goal description.

9.3.1.3 Creation of Interfaces and Grounding

Interfaces describe service behavior, modeled in WSMO as (i) choreography de-
scribing how service functionality can be consumed by service requester and (ii)
orchestration describing how the same functionality is aggregated out of other ser-
vices (in our example, we only model choreography interfaces as we currently do

9.3 Illustration by a Larger Example

(cid:2)
/∗ late-bindingchoreographyforservicediscoverystage ∗/
choreography dlb#DiscoveryLateBindingChoreography

stateSignature

in mu#purchaseQuoteReq withGrounding { ... }
out mu#PurchaseQuoteResp withGrounding { ... }

forall

{?purchaseQuoteReq} with (

?purchaseRequest memberOf mu#PurchaseQuoteReq
) do

add( # memberOf mu#PurchaseQuoteResp)

endForall

...

/∗ executionchoreographyforserviceexecutionstage ∗/
choreography exc#ExecutionChoreography

stateSignature

in mu#SearchCustomerRequest withGrounding { ... }
out mu#SearchCustomerResponse withGrounding { ... }

transitionRules MoonChoreographyRules

forall

{?request} with (
?request memberOf mu#SearchCustomerRequest

) do

add(_# memberOf mu#SearchCustomerResponse)

endForall

...(cid:4)

Listing 9.2 CRM/OMS choreography

205
(cid:3)

(cid:5)

not use WSMO service orchestration). The interfaces in WSMO are described us-
ing Abstract State Machines (ASM) deﬁning rules modeling interactions performed
by the service including grounding deﬁnition for invocation of underlying WSDL
operations. In our architecture and with respect to types of interactions between
service requester/provider and the middleware, we distinguish two types of chore-
ography deﬁnitions, namely late-binding choreography and execution choreogra-
phy. Listing 9.2 shows a fragment depicting these two choreographies for the CR-
M/OMS service. The ﬁrst choreography, marked as DiscoveryLateBindingChore-
ography, deﬁnes the rule how to get the quote for the desired product from purchase
order request (here, the concept PurchaseQuoteReq must be mapped to correspond-
ing information conveyed by the purchase order request sent by the Blue). This
rule is processed during the service discovery and the quote information obtained
is used to determine whether a concrete service satisﬁes the request (e.g., if the
requested product is available, which is determined through quote response). The
second choreography, marked as ExecutionChoreography, deﬁnes how to get in-
formation about customer from the CRM system. Decision of which choreography
should be used at which stage of execution (i.e., service discovery or conversa-
tion) is determined by the choreography namespace (in the listing this namespace is
identiﬁed using preﬁxes dlb# for discovery late-binding and exc# for execution, re-
spectively). In general, choreographies are described from the service point of view.
For example, the rule on line 21 says that in order to send SearchCustomerResponse
message, the SearchCustomerRequest message must be available. By executing the
action of the rule (add(SearchCustomerResponse)), the underlying operation with

206

(cid:2)
axiom mapping001 deﬁnedBy

9 The Web Service Execution Environment
(cid:3)

mediated(X, o2#searchString) memberOf o2#searchString :−
X memberOf o1#customerId.

(cid:4)

(cid:5)

Listing 9.3 Mapping rules in WSML

corresponding message is invoked according to the grounding deﬁnition of the mes-
sage which, in turn, results in receiving instance data from the Web service.

9.3.1.4 Creation of Ontology Mappings

Mappings between used ontologies must be deﬁned and stored in the middleware
repositories before execution. In Listing 9.3, the mapping of the searchString con-
cept of the CRM/OMS ontology to concepts cusomterId of the PIP3A4 ontology
is shown. The construct mediated(X, C) represents the identiﬁer of the newly cre-
ated target instance, where X is the source instance that is transformed, and C is
the target concept we map to. Such a format of mapping rules is generated from the
ontology mapping process by the WSMT ontology mapping tool.

9.3.2 Execution of Services

In this section, we describe the execution phase run in the middleware for our exam-
ple. This phase is depicted in Fig. 9.11 and implements the AchieveGoal execution
semantics. We further divide this phase into the following stages to which we refer
using numbers before each paragraph: (i) Sending Request, (ii) Late-Binding–
Discovery, Selection and Conversation Set-up, (iii) Execution–Conversation
with Service Provider, (iv) Execution–Conversation with Service Requester.

9.3.2.1 (i) Sending Request

A RosettaNet PIP3A4 PO message is sent from the Blue Company to the entry
point of the PIP3A4 adapter. In the PIP3A4 adapter, the PO XML message is lifted
to WSML according to the PIP3A4 ontology and the rules for lifting using XSLT.
Finally, a WSMO Goal is created from the PO message, including the deﬁnition of
the desired capability and choreography as well as instance data (this goal is created
as an abstract goal which contains separately deﬁned data). The capability of the
requester (Blue company) is used during the discovery process whereas the Goal
choreography describes how the requester wishes to interact with the environment.
After the Goal is created, it is sent together with the data to middleware by invoking
the AchieveGoal execution entrypoint.

9.3 Illustration by a Larger Example

207

Fig. 9.11 Sequence diagram

9.3.2.2 (ii) Late-Binding–Discovery, Selection, and Conversation Set-up

The AchieveGoal execution entrypoint is implemented by the Communication ser-
vice which facilitates inbound and outbound communication with the middleware.
The AchieveGoal execution entrypoint starts the AchieveGoal execution semantics
which performs the following steps:
• The parser parses the message into the internal memory representation.
• The discovery ﬁnds appropriate services by processing their abstract descriptions,
that is, by matching capability descriptions of the goal with each service’s capa-
bility descriptions from the repository.

• When a match is found at the abstract level, the match is further performed at
the instance level. For this purpose, discovery fetches some additional data from
service requester through processing of discovery late-binding interface of each
candidate service (if interface exists). Listing 9.2 shows such an interface for
Mueller’s service. Through this interface, discovery obtains some additional data
which is then used for ﬁne-grained querying of the knowledge base containing all

208

9 The Web Service Execution Environment

instance data of the goal and the candidate service. During this process, interac-
tions with data mediation as well as communication services are also performed
(for brevity, these are not shown in Fig. 9.11). Upon result, the list of services all
matching at the abstract and instance levels are returned.

• The next step is to perform the selection of the best service which satisﬁes service
requester’s preference. For this purpose, the preference on price is deﬁned as
part of the goal non-functional properties deﬁnition which is used for ranking of
candidate services in the list of discovered services. In our implementation, the
list is sorted by the reference property. The selection selects the ﬁrst service from
the list, in our case, it is the Mueller’s service.

• The ﬁnal step of this stage is to set-up the conversation between the service re-
quester and the selected service. For this purpose, loading of both the requester’s
(Goal) and the provider’s (selected service) choreography in the Orchestration
service is performed (these choreographies are part of the goal and service de-
scriptions). Both choreographies are then set to a state where they wait for in-
coming messages that could ﬁre a transition rule. This completes the conversation
set-up.

• In the next step, the Blue can send the data according to the Blue’s goal choreog-
raphy deﬁnitions. However, since our implementation is a bit simpliﬁed, all data
from the Blue is already in the goal description. The execution semantics extracts
all the data from the goal description and passes them to the process mediation to
decide which data to add to requester’s or provider’s choreographies (this deci-
sion is based on the analysis of both choreographies and concepts used by these
choreographies). Process Mediation service ﬁrst updates the memory of the re-
quester’s choreography with the information that the PO request has been sent.
The Process Mediation then evaluates how data should be added to the memory
of the provider’s choreography—data must be ﬁrst mediated to the ontology used
by the provider. For this purpose, the source ontology of the requester, target on-
tology of the provider and the instance data are passed to the Data Mediation ser-
vice. Data mediation is performed by execution of mapping rules between both
ontologies (these mapping rules are stored within middleware repositories and
have been created during the Business Service Modeling phase).

9.3.2.3 (iii) Execution–Conversation with Service Provider

Once the requester’s and provider’s choreographies have been updated, the Orches-
tration service processes each to evaluate if any transition rules can be ﬁred. The
requester’s choreography remains in the waiting state as no rule can be evaluated at
this stage. For the provider’s choreography, the Orchestration service ﬁnds the rule
shown in Listing 9.2 (lines 8–12). Here, the Orchestration service matches the data
in the memory with the antecedent of the rule and performs the action of the rule’s
consequent. The rule says that the message SearchCustomerRequest with data
searchString should be sent to the service provider (this data has been previously
added to the processing memory after the mediation—here, searchString corre-
sponds to the customerId from the requester’s ontology). The Orchestration service

9.3 Illustration by a Larger Example

209

then waits for the SearchCustomerResponse message to be sent as a response from
the provider. Sending the message to the service provider is initiated by Orchestra-
tion service passing the message to the Communication service which, according to
the grounding deﬁned in the choreography, passes the message to the searchCus-
tomer entrypoint of the CRM/OMS Adapter. In the adapter, lowering of the WSML
message to XML is performed using the lowering rules for the CRM/OMS ontology
and the CRM XML Schema. After that, the actual service of the CRM system behind
the adapter is invoked, passing the parameter of the searchString. The CRM sys-
tem returns back to the CRM/OMS Adapter a resulting customerObject captured
in XML. The XML data is lifted to the CRM/OMS ontology, passed to middleware,
evaluated by the Process Mediaton service and added to the provider’s choreogra-
phy memory. Once the memory of the provider’s choreography is updated, the next
rule is evaluated resulting in sending a createNewOrder message to the Mueller’s
service (OMS system). This process is analogous to the one described before. As a
result, the orderID sent out from the OMS system is again added to the memory of
the provider’s choreography. After the order is created (opened) in the OMS system,
the individual items to be ordered need to be added to that order. These items were
previously sent in one message as part of order request from Blue’s RosettaNet sys-
tem (i.e., a collection of ProductLineItem) which must be now sent to the OMS
system individually. As part of the data mediation in step (ii), the collection of items
from the RosettaNet order request were split into individual items whose format is
described by the provider’s ontology. At that stage, the Process Mediation service
also added these items into the provider’s choreography. The next rule to be evalu-
ated now is the rule of sending the addLineItem message with data of one lineItem
from the processing memory. Since there is more then one line item in the memory,
this rule will be evaluated several times until all line items from the ontology have
been sent to the OMS system. When all line items have been sent, the next rule is
to close the order in the OMS system. The closeOrder message is sent out from the
middleware to the OMS system and since no additional rules from the provider’s
choreography can be evaluated, the choreography comes to the end of conversation
state.

9.3.2.4 (iv) Execution–Conversation with Service Requester

When the order in OMS system is closed, the OMS system replies with orderCon-
ﬁrmation. After lifting and parsing of the message, the Process Mediation service
ﬁrst calls for the mediation of the data to the requester’s ontology and then adds the
data to the memory of the requester’s choreography. The next rule of the requester’s
choreography can be then evaluated which says that the purchaseOrderConﬁr-
mation message needs to be sent to the RosettaNet system. After the message is
sent, no additional rules can be evaluated from the requester’s choreography, thus
the choreography comes to the end of conversation state. Since both requester’s and
provider’s choreography are in the state of end of conversation, the Orchestration
service closes the conversation.

210

9 The Web Service Execution Environment

9.4 Possible Extensions

The reference implementation of the SESA middleware is constantly evolving in
order to incorporate additional functionality. Additionally, complete synchronous
behavior of the presented Execution Semantics has proven to be a limiting factor in
situations when a service consumer is continuously interested in services capable
to fulﬁlling its needs. The solution can be found in a goal subscription mechanism
based on asynchronous communication model.

9.4.1 Goal Subscription

Large scale applications are demanding for more and more support of loosely cou-
pled distributed interaction mechanisms. The Publish/Subscribe paradigm adapts
well to the need, thus gaining momentum in the Web service community (e.g., WS-
Events, WS-Notiﬁcation). The main goal of such a mechanism is decoupling in
time, space and synchronization publishers and subscribers. One current limitation
of existing standards and supporting middleware is the need for the subscriber to
know the topic offered by the publisher and to be able to process natively the pub-
lished messages. The architecture of the semantically enabled middleware for Pub-
lish/Subscribe applications is based on the Semantically Enabled Service Oriented
Architectures (SESA), enhanced with message brokering capability following the
paradigm.

The existing WSMX behavioral models are based on the synchronous messaging
paradigm. In order to support for asynchronous message processing, a new compo-
nent called Notiﬁcation Broker is introduced into the WSMX stack (as depicted in
Fig. 9.12). The functionality of the component targets overcoming some shortcuts
of the WS-Notiﬁcation speciﬁcation [10]. In particular, WS-Notiﬁcation requires
knowledge of the hierarchy topic prior to binding to the particular one. Furthermore,
WS-Notiﬁcation deﬁnes three types of ﬁlters (Topic ﬁlter, Message ﬁlter, Producer
state ﬁlter) which base their functionality on XPath [4] expression processing over
rather constrained data space.

The broker’s operation relies upon the processing of data represented in an onto-
logical format. In this way, both subscribers and producers of the messages can em-
ploy powerful knowledge description formalism (i.e., Web Service Modeling Lan-
guage [5]) in order to precisely describe their needs. Topic hierarchies of arbitrary
complexity can be described in terms of ontologies. Furthermore, ﬁltering rules can
be represented in the form of axioms which could govern speciﬁc constrains over
the WSMX knowledge base. Synergy of the data mediator and the notiﬁcation bro-
ker, operating on the semantic level, adds additional level of indirection between
individual data formats of parties interested in communication over the messaging
infrastructure.

The introduction of the Notiﬁcation Broker enables also WSMX itself to be a
subscriber and to trigger a proper execution semantics according to incoming mes-
sages, making it not only a Semantically enabled SoA, but also a Semantically en-
abled EDA (Event Driven Architecture).

9.4 Possible Extensions

211

Fig. 9.12 The extension of the WSMX with message broker component

Fig. 9.13 The execution semantics of the Publish (lower part) and Subscribe (top part) entry
points

Figure 9.13 presents the execution semantics of the Publish and Subscribe entry
points. In the case of the Subscribe execution semantics, when a subscribe message
is received by the Communication Manager (i), the message is then forwarded to
the Message Broker (ii); at this point the Message Broker registers the subscription
and, to support the caching mechanism, forwards the subscription message to the

212

9 The Web Service Execution Environment

Fig. 9.14 The adapted achieveGoal execution semantics

Data Mediator (iii); the Data Mediator mediates the subscription to transform the
subscribed topic concept and the ﬁltering query contained in the subscription mes-
sage according to the ontologies registered in the middleware by the Publishers. The
mediated subscriptions are forwarded to the Message Broker (iv) that caches for op-
timization the mediated ﬁltering queries and topic concepts. Finally, the control is
returned to the Communication Manager (vi) that acknowledges the Subscriber (vii).
With regards to the Publish execution semantics, when a publish message is
received (i), the message is then forwarded to the Message Broker (ii); at this point,
the Message Broker uses the cache to ﬁnd out possible matching subscriptions and
applies registered mediated queries to complete the matching of the message against
subscriptions (iii); the message is sent to the Data Mediator (iv) that mediates the
published message to the ontologies of the matching subscriptions. The mediated
messages are returned to the Message Broker (v) that returns the control to the
Communication Manager (vi) that notiﬁes the matched Subscribers (vii).

The achieveGoal entry point allows ﬁnding a service that matches user’s goals
and actually invoking it. WSMX may play both the role of a subscriber and a pub-
lisher, by introducing some small changes to the achieveGoal execution semantics
(see Fig. 9.14). When a user invokes the achieveGoal entry point by sending a
goal (i), the Discovery engine picks up the goal and tries to match it against reg-
istered services (ii). At this point, in the original execution semantics, if a matching
service is not found, the user is informed that no matching service was found. In
the modiﬁed version discussed here, a “service not found” message is notiﬁed to
subscribed service providers, containing also the speciﬁcation of the desired service
(iii–v). When a Provider creates a new service and registers it to the middleware
(vi), the service is stored by the Resource Manager (vii) that issues a “new service”
message to the Message Broker (viii). At this point, the Message Broker notiﬁes the
pending Discovery processes (if, according to the user policy, they are not expired)

9.5 Summary

213

and restores them (ix); at this point, the original goal is tested against new regis-
tered services (x) and if it matches any of them, one is selected and invoked as in
the original execution semantics (xi–xii). Finally, the results of the invocation are
dispatched to the Message Broker (xiii) that triggers the Communication Manager
(xiv) to send notiﬁcation of the requested service execution to the User (xv).

9.5 Summary

This chapter presented basic notions comprising Semantically enabled Service Ori-
ented Architecture (SESA). At the beginning, we introduced basic motivation for
having SESA, by laying down its background and governing principles. Further-
more, a notion of Execution Environment for Semantic Web Services was intro-
duced together with accompanying challenges.

The chapter continued with a discussion related to SESA technical solution
where SESA was represented as a multi-layered system composed of stakeholders’
layer, broker layer, base layer, and vertical services. Special attention was devoted
to the description of speciﬁc broker and base services which comprise SESA mid-
dleware. We introduced the notion of Execution Semantics together with main three
implementations. This discussion was followed by an example which tended to give
a solution to the B2B integration problem. The chapter concluded with a discussion
of possible SESA extensions, namely goal subscription.

9.6 Exercises

Exercise 1 Given the following scenario description, try to formulate a set of
WSMO ontologies and service descriptions.

With an invocation of one of the Web services, you can order a package ship-
ment by specifying sender’s address, receiver’s address, package information, and
a collection interval during which the shipper will come to your premises to collect
the package. A shipper either responds with the estimated pickup (respecting the
given time constraints) or with a fault message indicating that a pick up is not possi-
ble in the requested time interval. We have four distinct shippers with the following
constraints:

Racer

• Rates (ﬂat fee/each lb): Europe (41/6.75), Asia (47.5/7.15), North America
(26.25,4.15), Rates for South America as for North America, Rates for Oceania
as for Asia; Furthermore, for each collection order, 12.50 is added!

• The list of countries Racer ships to is included in a WSDL ﬁle.
• Only packages weighing 70 lbs or less are shipped.
• Constraints on Collection:

214

9 The Web Service Execution Environment

– There should be at least an interval of 120 minutes for collection.
– Latest Collection time is 8 pm.

• Delivery Time

– Ships in 2/3 (domestic/international) business days if collected by 6 pm.

Runner
• Rates (ﬂat fee/each lb): Europe (50/5.75), Asia (60/8.5), North America (15/0.5),
South America (65.75/12), Africa (96.75/13.5), Oceania has the same rates as
Asia.

• The exact list of countries is included in a WSDL ﬁle.
• When ordering a shipment using the Web services, the shipment of one package

can be ordered per invocation.

• If the package weight exceeds 70 lbs, weight, length and height are required (the

order has to be done via phone or fax).

• Constraints on Collection:

– Collection can be ordered maximum 5 working days in advance.
– Minimum Advance notice for collection is 1 hour.
– Collection is possible between 1 am–12 pm (keep in mind that 12 pm is noon!).
– There must be at least an interval of 30 minutes for collection.

• Delivery Time:

– Ships in 2 business days if collected by 10 am.
– Ships in 3 business days otherwise.

Walker
• Rates (ﬂat fee/each lb): Europe (41/5.5), Asia (65/10), North America (34.5/3),

South America (59/12.3), Africa (85.03/13), Rates for Oceania as for Asia.

• Only packages weighing 50 lbs or less are shipped.
• The exact list of countries is included in a WSDL ﬁle.
• Constraints on Collection:

– Shipment can be ordered maximum 2 business days in advance (the end of the
pickup interval must be at most two business days in advance at the time of
ordering).

– Pickup time must be between 6 am and 11 pm.
– There must be at least an interval of 30 minutes for collection.

• Delivery Time

– Ships in 2 business days if collected by 5 pm.

Weasel
• Rates (ﬂat fee/each lb): United States (10/1.5).
• Delivery in the United States only.
• Constraints on Collection:

– The pick up interval must be at least 5 hours.
– The maximum pick up interval is 4 days.
– Collection can be ordered until 8 pm.

References

• Delivery Time

– 1 day if collected before 2 pm.

Next, try to express WSMO goals following given constraints:

215

Goal A1

• Destination: Tunis
• Package dimensions: (l/w/h) 7/6/4 (inch)
• Package weight: 1 lb

Goal A2

• Destination: Luxembourg
• Package dimensions: (l/w/h) 7/7/5 (inch)
• Package weight: 1.5 lb

Goal B1

• Destination: Tunis
• Package dimensions: (l/w/h) 40/10/10 (inch)
• Package weight: 30 lb

Goal B2

• Destination: Bristol
• Package dimensions: (l/w/h) 40/24/10 (inch)
• Package weight: 30 lb

Discuss which Web services are fulﬁlling each of the aforementioned goals.

References

1. Booth, D., Hugo Haas, W., McCabe, F., Newcomer, E., Champion, M., Ferris, C., Orchard,
D.: Web Service Architecture. W3C, Working Notes (2003/2004). http://www.w3.org/TR/
ws-arch/

2. Burbeck, S.: The

of
developerworks/library/ws-tao/

tao

e-business

services

(2000).

http://www-128.ibm.com/

3. Clancey, W.J.: Heuristic classiﬁcation. Artiﬁcial

Intelligence 27(3), 289–350 (1985).

doi:10.1109/MC.2004.172

4. Clark, J., DeRose, S. (eds.): XML Path Language (xpath) Version 1.0. W3C Recommendation

(1999). http://www.w3.org/TR/xpath

5. de Bruijn, J., Lausen, H., Polleres, A., Fensel, D.: The web service modeling language wsml:
an overview. In: Sure, Y., Domingue, J. (eds.) ESWC. Lecture Notes in Computer Science,
vol. 4011, pp. 590–604. Springer, Berlin (2006)

6. Dijkstra, E.W.: Notes on structured programming. Tech. rep. (1972)
7. Eshuis, H.: Semantics and veriﬁcation of uml activity diagrams for workﬂow modelling. PhD

thesis, University of Twente, Twente, Netherlands (2002)

216

9 The Web Service Execution Environment

8. Fensel, D., Keller, U., Lausen, H., Polleres, A., Toma, I.: Www or what is wrong with
web service discovery. Tech. rep. (2005). Available at http://www.w3.org/2005/04/FSWS/
Submissions/50/WWW_or_What_is_Wrong_with_Web_service_Discovery.pdf

9. Gelernter, D., Carriero, N., Chang, S.: Parallel programming in Linda. In: Proceedings of the

International Conference on Parallel Processing (1985)

10. Graham, S., Niblett, P., Chappell, D., Lewis, A., Nagaratnam, N., Parikh, J., Patil, S., Sam-
darshi, S., Tuecke, S., Vambenepe, W., Weihl, B.: Web services notiﬁcation. Technical report,
IBM, Akamai Technologies, Computer Associates International, SAP AG, Fujitsu Laborato-
ries of Europe, Globus, Hewlett-Packard, Sonic Software, TIBCO Software (2004)

11. Harel, D., Rumpe, B.: Meaningful modeling: What’s the semantics of “semantics”? Computer

37(10), 64–72 (2004). doi:10.1109/MC.2004.172

12. Haselwanter, T.: WSMX core—A JMX microkernel. Bachelor Thesis (2005)
13. Keen, M., Acharya, A., Bishop, S., Hopkins, A., Nott, S.M.C., Robinson, R., Adams, J., Ver-
schueren, P.: Patterns: Implementing an SOA using an enterprise service bus. IBM Red Book
(2004)

14. Keller, U., Lara, R., Polleres, A., Toma, I., Kiffer, M., Fensel, D.: Web service modeling
ontology—discovery. Working draft, Digital Enterprise Research Institute (DERI) (2004).
Available from http://www.wsmo.org/2004/d5.1/v0.1

15. Mocan, A., Cimpian, E.: An ontology-based data mediation framework for semantic environ-

ments. International Journal on Semantic Web and Information Systems 3(2), 66–95 (2007)

16. Papazoglou, M.P.: Extending the service-oriented architecture. Business Integration Journal

(2002)

17. Papazoglou, M.P.: Service-oriented computing: concepts, characteristics and directions. In:
Proceedings of the Fourth International Conference on Web Information Systems Engineering.
WISE 2003 (2003)

18. Papazoglou, M.P., Ribbers, P.: e-Business: Organizational and Technical Foundations. Addi-

son Wesley, Reading (2006)

19. Papazoglou, M.P., van den Heuvel, W.-J.: Service oriented architectures: Approaches, tech-

nologies and research issues. VLDB Journal (2007)

20. Papazoglou, M.P., Traverso, P., Dustdar, S., Leymann, F.: Service-oriented computing research

roadmap (2006)

21. Singh, M.P., Huhns, M.N.: Service-oriented Computing: Semantics, Processes, Agents. Wiley,

New York (2005)

22. Toma, I., Roman, D., Fensel, D., Sapkota, B., Gomez, J.M.: A multi-criteria service ranking
approach based on non-functional properties rules evaluation. In: ICSOC ’07: Proceedings
of the 5th International Conference on Service-Oriented Computing, pp. 435–441. Springer,
Berlin (2007)

23. Wsmo4j—an api and a reference implementation for building semantic web services applica-

tions compliant with wsmo. Available at http://wsmo4j.sourceforge.net

Part III
Complementary Approaches for Web
Service Modeling Ontology

Chapter 10
Triple Space Computing for Semantic Web
Services

Abstract Semantic Web Services promise seamless interoperability of data and
applications on a semantic level, thus turning the Web from a world-wide infor-
mation repository for human consumption only to a device of distributed computa-
tion. To this end, appropriate semantic descriptions of Web services and intelligent
mechanisms working on this need a solid foundation in terms of the underlying
semantically-enabled communication technologies. Recent advances in middleware
technologies propose semantics-aware tuplespaces as an instrument for coping with
the arising requirements of scalability, heterogeneity and dynamism. An additional
argument is that Semantic Web Services have inherited the communication model
of XML-based Web services, which is based on message exchange, thus being a
priori incompatible with the REST architectural model of the Web. Analogously to
the conventional Web, truly Web-compliant service communication should be based
on persistent publication instead of message passing. In this chapter, we present
“Triple Space computing”, a Triple Space-based coordination middleware for Se-
mantic Web Services. We take a closer look at the respective data, infrastructure
and coordination models that enable the management of formal knowledge and that
support the interaction patterns characteristic for the Semantic Web and Semantic
Web Services. Applying Triple Space computing to Semantic Execution Environ-
ments and Service-Oriented Infrastructures is the second main topic of this chapter.

10.1 Motivation

Most of the available IT applications—and in particular Web services—depend
largely on synchronous communication links between information producers and
consumers. Instead of following the “persistently publish and read” paradigm of the
Web, traditional XML-based Web services establish tightly coupled communication
cycles and send directed messages back and forth. Indeed, aside from the name,
these Web services do not have much in common with the Web. This is similar to
the situation in the pre-Web age where one had to send an e-mail message to a sci-
entiﬁc colleague, asking for a speciﬁc paper or piece of information. In the current
Web that offers a communication infrastructure for humans, this pattern of com-
munication has widely been replaced by persistent publication and asynchronous
retrieval. We no longer request the biggest share of information in lengthy, syn-
chronous communication cycles with the originators, but fetch it from persistent

D. Fensel et al., Semantic Web Services,
DOI 10.1007/978-3-642-19193-0_10, © Springer-Verlag Berlin Heidelberg 2011

219

220

10 Triple Space Computing for Semantic Web Services

sources, for instance, the scientist’s personal Web page. We argue that this has sig-
niﬁcantly contributed to the success and scalability of the Web since it freed the
sender from the need to handle individual requests, and it made resources identi-
ﬁable and thus referable. Imagine one having to handle individual requests from
friends and colleagues who visit a Web site. The human certainly becomes the main
bottleneck for the dissemination of new ideas. The shift from information dissemi-
nation based on message exchanges to publication has not only made the Web scale
tremendously, but it has also accelerated the dissemination process. When compar-
ing Web services with this important principle of the Web, it becomes obvious that
Web services are not following the core idea of the Web. It is true that Web services
use the Internet as the transport medium, however, that is basically all they have in
common with the Web.1

The negative side-effect of distributed applications that communicate via mes-
sage exchange is that they require a strong coupling in terms of reference and time.
This means that the sender and receiver of data must (i) maintain a connection at
the very same time, (ii) agree on the data format, and (iii) know each other and
share a common representation. Therefore, the communication has to be directed
to a particular service endpoint and is synchronous as long as neither party imple-
ments asynchronous communication (or the two jointly agree on the speciﬁc way
this mechanism is implemented).

The above statement is in alignment with the worries expressed by the REST
community [13]. Their two major criticisms on Web services were about the im-
proper usage of URIs and the violation of the stateless architecture of the Web.
It is one of the basic design principles of the Web and REST architecture to not
provide stateful protocols and resources [14, 27]. In practice this means that when
sending and receiving, for example, SOAP messages, the content of the information
is hidden in the body and not addressed as an explicit Web resource with its own
global and persistent URI. Therefore, most Web functionality dealing with caching
or security checks is disabled, since using it would require parsing and understand-
ing all possible XML schemas that can be used to write a SOAP message. Thus,
when a stateful conversation is required, this should be explicitly modeled by dif-
ferent URIs. Moreover, referring to the content transmitted via an explicit URI in
an HTTP-request would allow the content of a message to be treated like any other
Web resource and the scalability of the resulting service-based system would be
signiﬁcantly increased.

These arguments motivated the development of a new communication paradigm
at the intersection of tuplespace computing and semantics. Tuplespaces allow dis-
tributed sharing of information without requiring synchronous connections. The Se-
mantic Web extends the Web with machine processable semantic data, allowing
data exchange in heterogeneous application ﬁelds. Combining the two provides a

1In this line of reasoning, we obviously refer to XML-based Web services and similar communi-
cation protocols only. The recently emerging REST services pay tribute to many of the expressed
criticisms. Still, the principles and added value of Triple Space-based communication and coordi-
nation, as it will be presented later in this chapter, also apply to REST services.

10.2 Technical Solution

Fig. 10.1 Triple Space
conceptual architecture

221

communication paradigm with persistent and asynchronous dissemination via the
sharing of machine understandable data that we term “Triple Space computing”:
RDF triples provide a natural link from the Semantic Web and tuplespaces to Triple
Spaces [11]. In the next section, we explore how Web services can be fully lever-
aged by the aforementioned “persistently publish and read” Web principle and pro-
pose a means to overcome the major ﬂaws from which traditional IT service sys-
tems suffer. Notice, however, that the (Semantic) Web does not become obsolete
due to the Triple Space paradigm, nor will the message-based systems exchange
completely disappear as a communication paradigm for accessing computer func-
tionality remotely. Triple Spaces will supplement Web services, but will not replace
current technological approaches. Just as WWW technology has advanced message-
oriented communication means (e.g., phone or e-mail) for humans (Fig. 10.1), Triple
Space computing provides a complementary approach for machine-to-machine in-
teraction and leverages the true added value of service-oriented infrastructures.

10.2 Technical Solution

In order to understand the concepts of Triple Space computing, we start with an
introduction to tuplespace computing as a paradigm for exchanging data between
processes. Adding the concept of semantics of information naturally leads to se-
mantic tuplespaces and thus Triple Spaces.

10.2.1 Tuplespace Computing

Tuplespaces were ﬁrst introduced in the context of parallel programming languages
such as Linda to implement coordination between processes and were developed as
a means to inject the capability of concurrent programming into sequential program-
ming languages [16]. The principle is based on a simple communication interface
and a shared data space (tuplespace) which contains the data in the form of (tuples).
A tuple is an ordered list of typed ﬁelds, each of which either contains a value or is
undeﬁned. The coordination primitives are a small, yet elegant set of operations that
permit agents to emit a tuple into the space (operation out) or associatively retrieve

222

10 Triple Space Computing for Semantic Web Services

tuples either removing them (in) or not (rd). Retrieval is governed by matching rules.
Tuples are matched against a template which is a tuple that contains both literals and
typed variables. A match occurs if the template and the tuple have the same length
and ﬁeld types and if the value of literal ﬁelds are identical. The tuple (“N70241”,
EUR, 22.14) will match the template (“N70241”, ?currency, ?amount) and bind the
variables currency and amount to the values EUR and 22.14, respectively. The op-
erations are blocking and thus provide an inherited coordination mechanism.2 In
summary, a tuplespace
• supports asynchrony and concurrency, i.e., the producers and consumers of a
tuple do not need to know one another’s address nor exist concurrently (this is
also referred to as reference and time decoupling, respectively)

• permits associative addressing, i.e., data is retrieved on the basis of the type of

data requested, rather than on which speciﬁc data is referenced, and

• separates the coordination model from characteristics of the host implementa-

tion environment.

This decoupling has obvious design advantages for deﬁning reusable, distributed,
heterogeneous, and agile applications. A communication paradigm based on tu-
plespace computing also resembles the core Web paradigm: information is persis-
tently written on a globally accessible space where it is shared and can easily be
accessed without a cascade of message exchange operations. It is thus quite obvious
that the Web and tuplespaces share many underlying design principles. However,
current tuplespace models lack support for namespaces, semantics, and structure in
describing the information content of the tuples. In fact, tuplespaces provide a ﬂat
and simple data model that does not support any nesting or linking of data. Hence,
tuples with the same number of ﬁelds and ﬁeld order but different semantics cannot
be distinguished. Triple Space computing thus had to extend tuplespaces to enhance
the common ﬁeld structure and ﬁeld comparison matching with nested and inter-
linked tuples (triples) and semantics-aware matching rules. Parts of these extensions
are directly addressed by existing Web technology for resource identiﬁcation in the
Web:

1. URIs provide a reference mechanism that allows information to be distinguished

on a world-wide scale.

2. Namespaces provide a separation mechanism that allows different applications

to use the same vocabulary without blurring their communication.

In order to comply to the requirements of large scale Semantic Web applications,
there is a further need to extend the tuplespace models in several directions. We
distinguish between three categories of extensions to the original approach: (i) new
types of tuples, (ii) new types of tuplespaces, and (iii) new types of operations.

The ﬁrst extension looks at the necessary changes to tuples and tuple ﬁelds. The
Semantic Web is mainly about the meaning of Web resources and their properties.

2The original Linda language included a further operation, eval, that is not exploited in Triple
Space computing and thus not further discussed in this chapter.

10.2 Technical Solution

223

The ﬁrst problem with traditional tuplespace implementations is that tuples with the
same number of ﬁelds and the same ﬁeld typing cannot be distinguished, which does
not comply with the Semantic Web principle which foresees that all information is
encoded in triples of URIs. Moreover, as stated previously, the different semantic tu-
ples in a space are not independent as, for example, in the Linda language, but highly
correlated and dependent upon each other (semantic statements are connected in the
so-called RDF graphs). Hence, the Semantic Web requires a reconsideration of the
tuple model and the way tuples are matched in accordance with these concepts. The
matching algorithms have to consider the meaning of the semantic tuples in order
to provide the required degree of knowledge interpretation, and allow the retrieval
of tuples taking into account the relationship to other tuples in the same space. This
relates especially to the issues of resource identiﬁcation previously discussed.

The second category of extensions aims at overcoming the technical problems of
large scale distributed systems (e.g., heterogeneity, scalability, fault-tolerance, mul-
tiuser access) by proposing distribution strategies for multiple spaces or hierarchic
spaces and augmented naming approaches. Such approaches were already consid-
ered in various non-semantic tuplespace implementations applied to solve commu-
nication and coordination issues in areas such as open distributed systems, workﬂow
execution, or XML middleware [2, 5, 6, 23, 26].

The last type of extensions reconsiders the tuplespace operations for publishing
and retrieving tuples. Rather than handling individual tuples, in the context of the
Semantic Web, we have to be able to work at the level of resources, semantic state-
ments and graphs.

10.2.2 Triple Space Computing

Tuplespaces, as we discussed above, can help to overcome heterogeneity in com-
munication and coordination, however, they do not provide an answer to data het-
erogeneity. That remains a task for the Semantic Web, as it provides standards to
represent machine-processable semantics of data. In RDF [17], semantic data is
described by interlinked triples of the form <subject, predicate, object>. The sub-
ject is the resource about which the statement is made. The predicate represents a
speciﬁc property and the object is either a resource or a literal deﬁning the prop-
erty value of the statement. Resources are identiﬁed by URIs, while literals are, for
instance, strings or numbers. RDF Schema [1] additionally deﬁnes classes, proper-
ties, domain and range inferences, and hierarchies of classes and properties on top
of RDF. Therefore, a richer data model other than interlinked triples could also be
used to model and retrieve information. This is even further extended by OWL [20],
a data modeling language based on description logic. The Semantic Web aims at
making problems in protocol and process heterogeneity transparent by its uniform
and simple means for accessing and retrieving information. Space-based computing
moreover allows complex message exchanges to be replaced by simple read and
write operations in a globally accessible space. Therefore, Triple Spaces deliver a

224

10 Triple Space Computing for Semantic Web Services

global platform for application and service integration on the Internet just as tu-
plespace computing became a means for the local integration of parallel processes.
In other words, Triple Spaces enable machines to use an equally powerful commu-
nication medium as the WWW provides for humans.

To conclude this section, we highlight again the advantages for providers and
consumers of semantic data that arise from the introduction of Triple Space com-
puting. The providers of data can publish it at any point in time (time autonomy),
independent of its internal storage (location autonomy), independent of the knowl-
edge about potential readers (reference autonomy), and independent of its internal
data schema (schema autonomy):
• Time autonomy There is a only minimal time dependency between the data
provider and reader, in the sense that a triple must ﬁrst be written before it can be
retrieved.

• Location autonomy The Triple Space as a storage location is independent of
the storage space of the providers or readers of data. Complete independence is
achieved by ensuring that triples are passed to and from the Triple Space by value
and in the format required by the Triple Space.

• Reference autonomy Provider and reader of data might know about each other,
but ex ante knowledge for purposes of communication through the Triple Space is
not required. In the simplest case, the reading and writing of data is anonymous.
• Data schema autonomy Triple Space computing provides its own schema (based
on triples according to RDF) and the data written and retrieved from a Triple
Space will follow that data model. This makes the provider and reader indepen-
dent of their internal data schemas.

There are two further positive side-effects. A Triple Space provides a trustworthy
third-party infrastructure for data communication. Its involvement can enable secure
data exchange and business processes negotiation and communication. Lastly, the
Triple Space ensures persistent data storage. This guarantees that data is also avail-
able at a later point in time and that the data eventually can be read by all partners
involved in a data exchange. This enables the sharing of information for collabora-
tive activities.

10.2.3 Triple Space Conceptual Models

In the following, we present the conceptual speciﬁcation of a Triple Space system
including the space and data models, and the extended interaction primitives.

10.2.3.1 Data Models

In Sect. 10.2.2, we have already presented some of the similarities between tu-
plespaces and Triple Spaces in terms of their conceptual models. The data model

10.2 Technical Solution

225

of Triple Space alters the view on tuples towards established Semantic Web stan-
dards. Tuples receive the dimensions and semantics of RDF (<subject, predicate,
object>) and can be interlinked by use of shared URIs to form RDF graphs. Fol-
lowing the RDF abstract syntax, each tuple ﬁeld contains thus an URI (or, in the case
of the object, also a literal). In this way, tuples sharing the same subject, predicate
and object can still be addressed separately, which is consistent with the original
tuplespace model, while the sharing of resources (URIs) brings the RDF graph con-
cept to Triple Space computing. By associating graphs with globally unique iden-
tiﬁers, and thus by making graphs second-level resources in a space, sets of triples
become addressable and retrievable. This principle of making graphs manageable
resources has already proven useful in various other scenarios [3]. Graphs are then
referred to as named graphs, and are used, for example, in [4] to attach trust and se-
curity information to RDF data. Analogously, the Triple Space offers the possibility
to process entire semantic artifacts as one resource, e.g., Web service descriptions or
business orders. For such objects, it is advisable to consider them as one addressable
resource, rather then manipulating each triple individually, as this would normally
be the case when triples are the minimal data unit of a Triple Space. The graph iden-
tiﬁer is moreover used as a reference subject to add contextual data to the published
RDF data. Contextual information such as access log information does not differ
from one triple to another within a set that is written or accessed at the same time
(e.g., the time of publication or the owner/publisher). This metadata can be used to
reﬁne retrieval operations and to compute provenance and trust via (a) the sources
that delivered an answer or an indicator of how the answer was derived, and (b)
the recency of a published data item by means of the timestamps. In the context of
dataspaces—a novel view on distributed databases, where individual stores are no
longer integrated but rather coordinated in loosely-coupled manners—[15] mentions
metadata queries as an important element for the computation of the degree of un-
certainty of an answer. This is highly relevant in a world of virtualized information
providers, as they are enabled via Triple Spaces, because the origin of content can a
priori no longer be determined. The assumed quality of data is no longer bound to
the provider, but must be determined from a data item’s own context.

10.2.3.2 Space Model

There are two different possibilities to structure Triple Spaces: either by means of a
single space approach where the space abstracts from a single central server, as in
the original Linda, or a multiple spaces structure that partitions the global interac-
tion space. According to the partitioning strategy, it is further possible to differen-
tiate between ﬂat multiple spaces and hierarchical or nested spaces with the inter-
mediate tree-like structure. Table 10.1 summarizes this discussion. The single space
approach is not adequate for an infrastructure that aims at a global Triple Space plat-
form for the Semantic Web and Web services, as it results in a bottleneck and single
point of failure. This may become unacceptable in terms of performance and scal-
ability. On the other hand, the nested and interlinked approach, in particular when

226

10 Triple Space Computing for Semantic Web Services

Table 10.1 Possible space structures

Pros

Cons

Single

Flat

Nested

Tree

Simpliﬁed implementation, simple
access through single access point

Distribution of data possible, better
scalability

Single point of failure, bad scalability

No structuring, no dependencies and
relationships of spaces

High ﬂexibility in structuring spaces and
data

Difﬁculties in updating, high number of
dependencies

Allows layering and limited nesting of
spaces

Limited interlinking and dependencies

allowing overlapping spaces, necessitates complex data management mechanisms.
Consistency checking and updates over multiple spaces imply a high processing
overhead. The intermediate approaches of multiple ﬂat spaces, or tree-like spaces,
are more adequate for the goal of Triple Spaces. The ﬂat management provides a
simple means of organization, while the advantage of a tree-like space organization
is the possibility to partially merge a number of spaces within a parent space. The
former approach has, for example, been chosen by the TSC project [12], while the
later space structuring approach was applied by the TripCom project and has shown
to be effective for many of the targeted application scenarios [8, 19, 25].

In the continuation of this chapter, we rely on a tree-based space model in order
to cope with the increasing complexity of open decentralized systems in terms of
heterogeneity of applications and data, and the diversity and frequency of access.
The space model thus deﬁnes the global Triple Space to consist of a forest of space
trees in a meronymic structure. The overall space is composed of a set of disjoint
trees, in which every Triple Space may contain multiple subspaces, while it can be
contained in at most one parent. Triples are then associated with a single space, i.e.,
they are published to and maintained in only one space. Each space is identiﬁed
by its own URL, independent of its tree afﬁliation. This identiﬁer is important for
accessing the space, as we will see when discussing the interaction models.

Although the Triple Space provides only one Triple Space infrastructure (one
virtually singleton access point) to ensure scalability at the level of the applications
that are built on top of the space, the division into smaller spaces is essential to
guarantee scalability at the level of the platform as a whole. The number of servers
that manage a space, the number of triples published to a space, and the number
of users accessing a space inﬂuence the performance of the infrastructure in terms
of responsiveness and communication overhead. Therefore, it is important to in-
stall means to control these ﬁgures at the level of individual spaces. The goal of
installing spaces is to have dedicated means for information management, commu-
nication and coordination in the space layer. In other words, whenever there is a new
interaction context or a new group of clients that intend to collaborate through the
Triple Space platform, a new virtual space is installed that links together the interact-
ing data consumers and providers. There might be a space for sport news providers
and readers, and, independently, one for the processing of shoe orders. Any of these

10.2 Technical Solution

Table 10.2 Coordination
primitives for publication and
retrieval

227

1

2

3

write (URI space, Set(cid:2)Triple(cid:3) data):URI
read (URI space, Template t, [long timeout]):Set(cid:2)Triple(cid:3)
read (URI space, URI graph, [long timeout]):Set(cid:2)Triple(cid:3)

dedicated spaces can be hosted on a single machine, or shared amongst multiple co-
authorizing machines. This exempliﬁes the importance of P2P-driven technology in
Triple Space computing, as an arbitrary and dynamic number of machines should
be able to share a space without central control (cf. Sect. 10.2.4 on the Triple Space
architecture). This approach to space structuring guarantees at least local scalability
by naturally grouping related data and clients in dedicated spaces, and by inherently
limiting the scope of the individual interaction instances [18].

10.2.3.3 Interaction Model

The interaction model of the Triple Space provides operations for publishing and
retrieving semantic data in the form of RDF statements and RDF graphs (cf. Ta-
ble 10.2). Note that there are no removal operations deﬁned. In the context of dis-
tributed installations, the removal of data, or worse of knowledge, that includes the
deletion of inferred statements leads to complex data management issues and in-
evitably to decreased scalability. Omitting deletion seems to contradict the tradi-
tional CRUD functionalities (create, read, update, delete) of databases, however,
makes Triple Space operations manageable under the eminent scalability require-
ments. Nonetheless, it is indeed possible to model removal by means of the write
and read operations only. Instead of removing triples from a space, statements can
be marked as being invalid, e.g., by writing invalidating statements.3 The antipodal
coordination primitives for publication and retrieval are thus seen to be sufﬁciently
expressive.

The ﬁrst two operations in Table 10.2 represent the Triple Space versions of the
Linda ‘out’ and ‘rd’ primitives. The write operation asynchronously publishes a set
of triples to a given space, whereas the read operation retrieves triples matching the
given template from the indicated space. Templates are either triple or graph patterns
(see Table 10.3), or full-ﬂedged SPARQL CONSTRUCT queries [24]. Graph pat-
terns are the fundamental element of any RDF query language, and are supported
by most query engines. However, they have limited expressiveness compared to
SPARQL, e.g., no optional patterns, no alternative matches via UNION statements
and no ﬁlter expressions.

If the template is an SPARQL query, the indicated space can also be seen as a
simulation of an SPARQL-endpoint with the space URL as the endpoint locator.
Note that the retrieval operation does not give any guarantees with respect to the

3In the open world of the Web, this is an even stronger statement than ignorance. Even more, as
deletion on the Web cannot be guaranteed due to the caching and archiving of Web resources.

228

10 Triple Space Computing for Semantic Web Services

Table 10.3 Examples of semantic templates

Template

Description

?s a doap:Project;

foaf:member ?o.

Matches all triples where the subject is of type doap:Project and
where the same subject has triples indicating the members

?s ?p ?o.

Matches all triples where the object is of type foaf:Person

?o a foaf:Person.

?s foaf:name ?a;

foaf:mbox ?b.

Matches the triples that contain subjects for which the name and
a mailbox (foaf:mbox) are indicated

Table 10.4 Coordination primitives for publish–subscribe

4

5

6

7

advertise(URI space, Template t):URI

unadvertise(URI space, URI adv):void

subscribe(URI space, Template t, NotiﬁcationListener l):URI

unsubscribe(URI space, URI sub):void

completeness (i.e., the recall) of the set of triples returned. Analogously to tradi-
tional Linda spaces, querying only ensures that a triple that is published to a space
will eventually be retrieved. Retrieval could be invoked with an inﬁnite timeout, but
even under these circumstances, the Triple Space cannot guarantee full recall. In
the distributed scenarios that underlie the Triple Space platform, the state of a space
can change under the processing of a request, as further data might get published,
and locks would then be required to prevent this. Locking an open and distributed
system is, however, neither feasible nor even desirable. For identical reasons, there
is no guarantee of the consistency in terms of simultaneous accesses.

In order to offer Web-style access to resources, the template-based retrieval op-
eration is complemented with a URI-based primitive (Table 10.2(3)) that allows the
extraction of all the triples that are contained in the identiﬁed graph. Note that this
operation only returns one graph of all available ones. This alternative read opera-
tion emphasizes the convergence of space and Web technology: the data (triples) is
shared in a space, but retrieved as resources by their unique name, and not only by
Linda-like associative template matching.

Recall that one of the fundamental objectives of Triple Spaces in terms of com-
munication is the decoupling of producers and consumers of semantic artifacts.
While the read and write operations via spaces provide a ﬁrst step in this direc-
tion, they are still limited in terms of the decoupling of sequential operations of
individual consumers or producers. The publish–subscribe paradigm adds such an
additional dimension to the interaction patterns of the Triple Space. In systems based
on publish–subscribe, subscribers register their interest in an event, or a pattern of
events, and are subsequently asynchronously notiﬁed of events generated by pub-
lishers [10].

10.2 Technical Solution

Table 10.5 Management
operations

8

9

10

229

createSpace(URI space):void

joinSpace(URI space):void

leaveSpace(URI space):void

The operation (6) in Table 10.4 allows subscribers to express their interest in a
particular template. Upon the publication of matching triples, the subscribers are
notiﬁed. Publish-subscribe operations allow for long-term coordination of services
and applications. The operation (4) is put in place for publishers to advertise triple
patterns that are likely to match the data they intend to publish. While advertise-
ments are not necessary to realize the publish–subscribe functionality, they provide
a convenient means to optimize the match making between publications and sub-
scriptions. The methods ‘unadvertise’ and ‘unsubscribe’ are the inverse operations
to (4) and (6).

Besides the seven operations to publish and access semantic data in a space, the
Triple Space offers three management operations (Table 10.5). Administrators have
the possibility to create new spaces by means of the ‘createSpace’ operation.4 As
an effect of the creation of a space, the internal management structures are set up to
allow other client and machines to discover, access and join a space. By joining, we
refer to the process of becoming a co-administrator of a given space. While the cre-
ator of a space is per default the responsible host of a space, any other machine can
explicitly request to share a space by managing and storing some of the published
data (joinSpace as listed in Table 10.5(9)). The ‘leaveSpace’ operation inverts the
effects, and a machine retires from sharing a space by moving all the locally main-
tained triples to another co-administrator and releasing all bindings to the space. If
the machine that leaves happens to be the creator of the space, it needs to pass on
the role of primary host to another co-administrator of the space.

10.2.4 Triple Space Architecture

The Triple Space architecture fundamentally relies on distributed kernels. A so-
called Triple Space kernel is a single physical implementation consisting of all nec-
essary components that are needed to realize the functionality offered by the Triple
Space interaction model. Depending on the level of functionality provided, kernels
might have different sets of components. Any implementation, however, requires at
least the components for the implementation of the interaction model, for the man-
agement of the distributed space infrastructure, and for the integration of various
persistency frameworks, such as RDF repositories. Other possible components take

4The distinction between users and administrators is purely conceptual in the Triple Space as any
entity accessing the Triple Space infrastructure is only categorized in terms of the operations in-
voked, and not in terms of roles or rights.

230

10 Triple Space Computing for Semantic Web Services

Fig. 10.2 Triple Space conceptual architecture

care of data mediation, access control, or query optimization. The sum of these com-
ponents, i.e., a kernel instance, runs on a machine that is deployed on the physical
infrastructure underlying the Triple Space platform. Every kernel is addressable us-
ing a speciﬁc physical network address like a single physical machine or a single
physical cluster of machines.

The goal of Triple Space is to provide a scalable and distributed infrastructure.
Although scalability is a general property of a distributed system, its requirement
depends largely on application-speciﬁc needs in terms of functional properties such
as the type of operations, and non-functional properties such as availability, com-
pleteness, consistency or responsiveness [18]. Depending on the non-functional re-
quirements, a space might be hosted on only one machine or distributed across any
number of co-hosting peers (Fig. 10.2). While a space on a single machine real-
izes a Web server-like access point to RDF data, co-hosting kernels are organized
as equally positioned peers in a distributed system. Distributed spaces inherit the
advantages of the underlying network infrastructure: (i) there is no kernel that be-
comes a bottleneck and the single point of failure, (ii) having the measures in place
to distribute a space allows for scaling up the system by adding more kernels with
more processing power and memory (at the price of kernel coordination), and (iii)
provides ﬂexibility with respect to scalability-driven trade-offs, i.e., means to adjust
the availability, completeness or latency guarantees by increasing or decreasing the
degree of distribution. The Triple Space architecture hence allows for adding new
hardware and software resources without hindering the existing conﬁguration. The
overall perceived performance can be kept at the desired level, while system dy-
namism, openness, and increasing data and workload can be handled at the kernel
and space level, respectively.

10.2 Technical Solution

231

10.2.5 Triple Space and Semantic Web Services

The motivation for Triple Space computing was from the very beginning the en-
hancement of the communication and storage layer of Web services in general, and
Semantic Web Services in particular. Using Triple Space computing as paradigm for
the core infrastructure services of Semantic Execution Environments (SEE) enables
greater modularization, ﬂexibility and decoupling, and as a result thereof easier dis-
tribution and deployment, and ultimately more scalability in terms of computing on
the Web. In this section, we explain how Triple Space computing improves Seman-
tic Web Service infrastructures at different levels. The improvements are illustrated
by means of WSMX, the Web Service Execution Environment.

There are three main integration points for Triple Space and WSMX: external
communication grounding, component coordination and resource management. The
technological foundations of the integrations are subject to the next sections. In
Sect. 10.3, we provide moreover a larger and integrated example of how the com-
bination of WSMX and Triple Space adds a novel dimension to the Semantic Web
Service communication paradigm.

10.2.5.1 External Communication Grounding

Communication with service requestors or Semantic Web Services is an important
aspect of WSMX that can be signiﬁcantly improved by decoupling the different
communication partners in time and reference. Currently, driven by the message-
oriented communication paradigm underlying XML-based services, users commu-
nicate with WSMX and WSMX communicates with Web services via synchronous
remote procedure calls. In order to counteract this habit and to enable the use of
Triple Space, the external communication manager of WSMX has to be altered, i.e.,
the logics for sending and receiving messages has to be grounded to the interaction
models of Triple Space. This grounding happens at several distinct access points:

1. The invoker component of WSMX needs to support Triple Space-enabled WSDL

and SOAP bindings.

2. The entry point interfaces have to be linked to the space infrastructure in order
to provide the glue between existing Web service standards and Triple Space
computing.

3. The communication manager has to accept WSMO goals in RDF via the Triple

Space in order to enable fully decoupled invocation.

Without the addition of Triple Space as communication means, clients are tightly
coupled to the execution on WSMX. Amongst other things, the use of Triple Space
thus signiﬁcantly decreases the waiting time from clients, and makes the use of
WSMX a far more ﬂexible approach to Semantic Web Services.

232

10 Triple Space Computing for Semantic Web Services

Fig. 10.3 Triple Space-based Web service invocation

Grounding of Web Service Invoker The WSMX Web service invoker is part of
the communication manager component and is responsible for mapping an invoca-
tion of a WSMX-external Web service provider to the transport protocol supported
by the Web service. In combination with the WSMX grounding component, which
implements a bi-directional mapping between the semantic data models of WSMX
(WSMO-compliant objects) and the message and data format supported by external
Web service endpoints (e.g., SOAP messages), it delivers the necessary facilities for
the invocation of Web service endpoints.

In order to ground the Web service invoker in the Triple Space, an extended com-
ponent implementation maps the operations of the invoker interface to the operations
provided by the Triple Space interaction model. The mappings are offered by the
grounding component in addition to the transformation facilities for WSMO-based
semantic communication objects. Those are used within WSMX to transform (i)
messages that match the Triple Space data model (e.g., SOAP/RDF representations)
and (ii) message payloads that can be processed by the (Web) service provider. Fig-
ure 10.3 depicts the interaction scenario of asynchronous Triple Space-based Web
service invocation by WSMX: (i) WSMO to RDF grounding and publication into
the Triple Space, (ii) SOAP/RDF to SOAP/XML lifting, (iii) SOAP/XML to RDF
transformation and publication, and (iv) SOAP/RDF lifting back to the WSMX-
internal WSMO data models.

10.2 Technical Solution

233

Fig. 10.4 Client communication with WSMX via Triple Space

Grounding of Client End-Points The second type of grounding that is relevant in
the context of WSMX communication concerns either service providers or service
requesters that trigger read and write operations on the Triple Space, respectively.
A typical example is the communication between clients that contact WSMX in or-
der to register a service they offer or to ﬁnd relevant services. In the ﬁrst case, users
invoke a ‘publish’ operation on the WSMX communication manager (Fig. 10.4—
Step 1). For the latter case, to ﬁnd a service, WSMX offers the ‘achieveGoal’ oper-
ation (Fig. 10.4—Step 3).

To realize the two scenarios by means of the integrated Triple Space platform,
the interfaces of the communication manager are mapped to the interaction model
of the Triple Space, and the WSMX end-points have to be registered with the Triple
Space platform along with the appropriate graph patterns that have to be matched
as initiators to the execution of the component, i.e., the end-point registers for par-
ticular data constructs in order to be notiﬁed about incoming requests. With such
mappings in place, the resolving of a goal or the publication of a service can be me-
diated through the space infrastructure and thereby WSMX avoids the requirement
for synchronicity and reduces the communication overhead. Additionally, this ap-
proach offers the beneﬁt of effectively hiding the complexity of service interactions,
e.g., combining discovery and execution of one or more services to achieve a certain
goal, from the service requester.

Getting back to Fig. 10.4, Step 1 was already mentioned above. It represents the
registration of a new service description. In Step 2, the WSMX component responsi-

234

10 Triple Space Computing for Semantic Web Services

ble for publications of services is triggered, and the content of the registration is read
from the space and stored by the resource manager in the appropriate Triple Space
(details on the realization of a triple space-enabled resource manager are given later
in this section). A user request for a service via goal description (Step 3) triggers
the resource manager and a query is sent to the Triple Space in order to retrieve
the descriptions of services capable of handling the service requesters requirements
(Step 4). In Step 5, matching service descriptions are returned to the resource man-
ager, and WSMX starts to interact with service providers on behalf of the requester.
By means of the grounding mechanisms for the Web service invoker, such interac-
tions (Steps 6 and 7) can also be executed over a triple space. At last, in Step 8,
WSMX returns the result of the ‘achieveGoal’ invocation to service requester, pos-
sibly again via Triple Space.

10.2.5.2 Component Management in WSMX

The different components of WSMX are centrally managed by a core component
that is also in charge of enforcing the overall execution semantics [21]. In this way,
the various components provide the business logic, while the management logic is
implied by the WSMX core component. Every component is per design equipped
with a wrapper to handle its communication tasks. In order to coordinate the com-
ponents over Triple Space, the wrappers need be interfaced with Triple Space. The
manager then communicates with the different components by publishing RDF data
sets to the integration space, respectively by having components subscribed to par-
ticular triple patterns, i.e., components subscribe to pieces of data that are tailored
to trigger activities in the respective components. Moreover, the component man-
agement over Triple Space is designed in ways that make sure that the WSMX
manager can distinguish between the data ﬂow related to business logics (execution
of components based on the requirements of a concrete operational semantic) and
the data ﬂow related with the management logic (e.g., monitoring the components,
load-balancing, instantiation of threads).

The main adaptation with respect to non-Triple Space-based realizations at
the level of the communication wrappers is the addition of a Triple Space proxy
(Fig. 10.5). The proxies bind the wrappers to a Triple Space kernel instance by in-
corporating the functionalities of a space client on behalf of the component. In this
way, also adding a totally different communication paradigm between the manager
and the different components, Triple Space does not change any of the execution
semantics or WSMX internal component logic, nor even the interfaces of the com-
ponents. Note, moreover, that it is still the manager that determines which compo-
nents are used and have to be invoked. The addition of a Triple Space proxy solely
enables alternative communication means and deﬁnes how to invoke a particular
components by use of Triple Space primitives.

Grounding of Component Manager The implementation of the communication
wrappers without Triple Space shows nicely what advantages the new bindings pro-
vide. With space-based coordination, every wrapper would have to host a service

10.2 Technical Solution

235

e
c
a
p
S
e
l
p
i
r
T
r
e
v
o

n
o
i
t
a
n
i
d
r
o
o
c

t
n
e
n
o
p
m
o
c
X
M
S
W

5
.
0
1

.
g
i
F

236

10 Triple Space Computing for Semantic Web Services

Fig. 10.6 Alternative bindings: Triple Space “server” (left) or heavyweight proxies (right)

proxy for all other components. Adding new components or new functionality would
in consequence require an update to all wrappers whose components might need the
new value. Thanks to Triple Space, the proxies only implement the interface of the
space infrastructure and the communication between components is guided by the
publication of triples and the subscription to templates. The data that is exchanged
between components are WSMO objects that are formalized by means of the Web
Service Modeling Language (WSML, [7]) for which pre-deﬁned serializations to
RDF exist. Goal or service descriptions can thus be stored in the Triple Space as
identiﬁable RDF graphs, i.e., isolatable sets of triples. The task of the WSMX man-
ager becomes much simpler and is reduced to (i) the dispatching of requests to the
appropriate components by writing destined triple sets, and (ii) the monitoring of
the execution.

In terms of implementation, there are two distinguishable approaches, which both
have their advantages and disadvantages. Firstly, each proxy embeds its own Triple
Space kernel which transforms the proxies into rather heavyweight constructs. Sec-
ondly, the whole of WSMX offers one Triple Space kernel (server) to which the var-
ious proxies and the core connect remotely. This keeps the proxy implementation
simpler as they only have to implement a simple image of a kernel implementation.
A disadvantage of this approach is the fact that the kernel could become a bottle-
neck, as the chosen Triple Space adheres a single space model (Fig. 10.6); compare
as well with the discussion of space models in Sect. 10.2.3.2.

10.2 Technical Solution

237

Table 10.6 Resource management operation on Triple Space

Resource Manager API

Triple Space API

void saveGoal(Goal goal)

Set<identiﬁer> getGoalIdentiﬁers()

URI write(URI space, Set<Triple> ts)

Set<Triple> read(URI space, Template t,
long time)

Set<Identiﬁer> getGoalIdentiﬁers(Set<Object>
searchTerms, boolean conjunction)

Set<Triple> read(URI space, Template t,
long time)

Set<Identiﬁer> getGoalIdentiﬁers(Namespace
namespace)

Set<Triple> read(URI space, Template t,
long time)

boolean containsGoal(Identiﬁer id)

Goal loadGoal(Identiﬁer id)

Goal loadAllGoals()

Set<Triple> read(URI space, URI id, long
time)

Set<Triple> read(URI space, URI id, long
time)

Set<Triple> read(URI space, Template t,
long time)

10.2.5.3 Resource Management in WSMX

Besides delivering the publish and read functionality exploited above for the various
types of communication grounding and the component coordination, Triple Space
particularly also emphasizes on the persistency and sharing of data. As it was stated
in the section about the Triple Space architecture (Sect. 10.2.4), a persistency frame-
work in form of RDF repositories is a core element of a Triple Space kernel. The
persistency is exploited for the realization of a Triple Space-based resource manager
for WSMX.

Per design, WSMX has six different repositories. Four of them to store WSMO
ontologies, goals, mediators and services descriptions, and another two to store
events and intermediate instance data. In order to rely on uniﬁed and simple re-
source management procedures, WSMX makes use of the Triple Space to store
WSML data in the form of RDF graphs. To some degree, this is very similar to the
approaches described above for the grounding of invocations and the coordination
of components. This time, however, the aim is to improve the durability of informa-
tion objects rather then the exchange of information. Again, a ﬁrst requirement is the
transformation of WSMO top level entities from WSML into their RDF representa-
tion. A second requirement is the mapping of given WSMX resource management
operations to the Triple Space operations. To exemplify the correlation between re-
source management and data management with Triple Space, Table 10.6 outlines
the mappings of the goal-driven operations of the Resource Manager API onto the
Triple Space API, as it was introduced in Sect. 10.2.3.3.

With this outline we conclude the section on Triple Space-enhances Semantic
Execution Environments and turn to a related application area. While WSMX of-
fers the core infrastructure services and a number of broker services for the access
and management of Semantic Web Services, the so-termed Global Service Delivery
Platforms yield the main building blocks for Service-Oriented Architectures at the

238

10 Triple Space Computing for Semantic Web Services

Internet scale. In the next section, we take a look at how Triple Space computing is
an important enabler of such much larger service economies.

10.2.6 Triple Space and Semantic SOA

The integration of WSMX and Triple Space computing has shown, by means of
some simple examples, the added value that spaces bring to Semantic Web Ser-
vices. While WSMX is an early adopter of Triple Space technology, the future in
service computing is concerned with much more open and distributed environments.
Semantic Service-Oriented Architectures are the natural evolution of Semantic Ex-
ecution Environments by bringing the results of WSMX to the Web in order to
support the realization of the Service Web. The Service Web is one of the three
main building blocks of the Future Internet, and comprises the world of distributed
computing on the Web via composable and dynamically adjustable Web services.
In such a world where massive numbers of parties expose and consume services
by realizing a coherent and domain independent platform, scalability, ﬂexibility and
automation become even more crucial. Triple Space technology, with the aforemen-
tioned traits in terms of communication and coordination of distributed services, is
a core ingredient to the deployment of SOA in the large. In this section, we thus go
a step beyond WSMX over Triple Spaces and depict how a global service delivery
platform should look when blended with spaces and semantics.

The overall architecture of a global service-oriented infrastructure for the Service

Web can be structured into four main parts:

User front-end A rich Web platform that provides users with a uniﬁed view cover-
ing the whole life-cycle of services, including design-time provisioning, run-time
consumption and analysis.

Service cloud An infrastructural backbone on which various services are deployed
and over which distributed services communicate by exchanging or sharing data.
This is the part that is enhanced with Triple Space technology to move from tradi-
tional service bus solutions to the Service Cloud.

Platform services A set of services that provide the basic functionalities of the ser-
vice delivery platform, such as Service Ranking and Selection, Service Discovery,
Service Adaptation, Service Composition, Service Execution, and Reasoning Ser-
vices that are needed to support the automation of the other activities.

Web services The forth and last part comprises the business services (atomic or

composed) that are made available by end users.

Figure 10.7 depicts a high-level architecture of a Semantic SOA infrastructure
that offers an instance of a global service delivery platform. This infrastructure is an
outcome of a European research project called SOA4All whose aim is to transform
the Web into a domain where billions of services are coordinated in seamless and
transparent fashion, by integrating the service world of large enterprises, SMEs, and
end-users. Moreover, SOA4All seeks to bring the Service Web to the average user
by exploiting Web and Web2.0 technology, contextual information and not at least
semantics.

10.2 Technical Solution

239

d
u
o
l
c

e
c
i
v
r
e
s

e
h
t
n
i

s
e
c
a
p
S
e
l
p
i
r
T
h
t
i

w
A
O
S

7
.
0
1

.
g
i
F

240

10 Triple Space Computing for Semantic Web Services

Service Cloud In the very center of Fig. 10.7, there is the Service Cloud (in
SOA4All called Distributed Service Bus) that offers the core infrastructure needs
of the global service delivery platform. The Service Cloud takes on the role of
the enterprise service bus of traditional SOA systems by abstracting from service
particularities and implementation details. In order to enable a Semantic SOA at
the Web scale, it is necessary to extend traditional service bus solutions with tech-
niques to ease deployment, to cope with openness, dynamics and scalability in terms
of services, service providers and consumers, and certainly the resulting data and
work load on the system. In particular, when searching for novel solutions to the in-
creasing load, Triple Space-based solutions bring along obvious added value. Triple
Spaces can be used as a shared memory infrastructure to build repositories or to pro-
vide monitoring data about users, services and executions, and as a communication
infrastructure to enhance the traditionally message-oriented bus towards a publica-
tion infrastructure for anonymous and asynchronous service communication with a
notion of event-driven architecture; something currently not available from openly-
accessible enterprise service bus technology. More details describing how traditional
service bus solutions and Triple Space computing complement each other are given
in Sect. 10.2.6.1 below.

User Front-End and Platform Services On top of the service cloud, there is the
user front-end, in Fig. 10.7 termed SOA4All Studio, and at the bottom of the ﬁg-
ure, one can ﬁnd the platform services. The front-end is a fully Web-based user
platform that enables the creation, provisioning, consumption and analysis of Web
services that are published to global service delivery platform; this includes the use
of platform services. In the particular case of SOA4All, different types of users are
supported at different times of interaction. SOA4All knows two major groups of
users: (i) a large group of service consumers that use SOA4All for the consump-
tion of functionality that is provided by either platform services or by public Web
services, and (ii) a signiﬁcantly smaller group of (administrative) users that exploits
the capabilities of the platform services (via the SOA4All Studio) to annotate, select
and compose Web services. As stated above, the platform services deliver service
discovery, ranking and selection, composition and invocation functionality, respec-
tively, and are providers of the minimal functionality that is needed to establish a
service delivery platform. In that sense, they are very much comparable to WSMX
components in the examples of the previous section. As a whole, the ensemble of
service cloud, user front-end, and platform services exposes an instance of a fully
Web-based and Web-enabled service delivery platform: service integration and co-
ordination at the level of the cloud, Web-style service access via the user front-end,
and advanced state-of-the-art service processing, management and maintenance via
platform services.

(Semantic) Web Services The ﬁgure also shows the semantic service descriptions
and processes (composed services) that are created and processed by means of the
Semantic SOA infrastructure. First, Web services that are exposed either as tradi-
tional RESTful services or as traditional WSDL-based services (lower parts of the

10.2 Technical Solution

241

ﬁgure) are available. Those are invocable third-party business services that are en-
hanced in terms of automation, composition and invocation. Second, the top-left of
the ﬁgure depicts the semantic annotations of the business services, the so-called
Semantic Web Services. The semantic descriptions are published to the service
cloud, and used for reasoning with service capabilities (functionality), interfaces
and non-functional properties, as well as context data to deliver advanced and semi-
automated discovery, ranking and composition via platform services. Third, in the
top-right corner, light-weight processes and mash-ups are shown that are the basis
for the deﬁnition and execution of service compositions. Both, mash-ups and se-
mantic descriptions of service compositions are also published to the service cloud,
and become a public good for automated large-scale service computing.

10.2.6.1 Triple Space-Enhanced Service Delivery Platform

As explained in the previous section, the Service Cloud is the heart of the global
service delivery platform. Various challenges that come along with the use of service
infrastructures on the Web, such as heterogeneity, dynamics, openness and certainly
scalability, cannot be addressed with traditional service bus approaches. For this
reason, the service cloud that we present hereafter combines established enterprise
service bus technology with Triple Spaces. The enhancement with Triple Spaces
offers novel means for event-driven Web-style communication, coordination and
data sharing.

The primary goal of the Service Cloud is to ensure that the Semantic SOA scales
to the dimensions of the Web, by enabling appropriate distribution techniques that
evolve the service buses towards a fully distributed middleware for service coor-
dination and communication without altering standard interaction patterns used in
XML-based SOA. While state-of-the-art service technology still mostly relies on
client–server communication, as it was discussed in the beginning of this chapter
(cf. Sect. 10.1), the service cloud can offer more powerful communication patterns
thanks to Triple Space computing, e.g., publish–subscribe, event-driven, semantics-
based communication means that allow for further decoupling of the communicat-
ing entities in terms of time, processing ﬂow and data schema. In particular, the
integrated support for semantics empowers direct links to reasoning or mediation
techniques. By adding Triple Spaces, the Service Cloud moreover realizes an inte-
grated infrastructure that grants access to
• Asynchronous and/or event-driven communication.
• Distributed semantic repositories for service, goal and process descriptions.
• A storage infrastructure for sharing monitoring and user data.
• And a computation platform for various types of collaborative activities.

It is important to note that all of the above are delivered without requiring any
of the platform services and public Web services to take care of additional access
points, i.e., the Service Cloud provides an all-in-one solution for service computing
on the Web. This is an important principle and enabler for a SOA that scales be-
yond the boundaries of corporate networks. The Service Cloud allows any type of

242

10 Triple Space Computing for Semantic Web Services

communication efﬁciently and transparently over the Web by means of sharing or
exchanging any type of data in between any type and number of distributed actors.
In summary, the Service Cloud exposes the traditional enterprise service bus
functionality extended with scalable Web-style publishing and reading, integrated
support for semantics and event-based communication mechanisms as basis for
shared data management and collaborative activities. Thanks to the Web principles
added by the integrated Triple Space infrastructure, the Service Cloud is offering
the core infrastructure services that are necessary for the realization of the Service
Web.

10.2.6.2 Service Federations in the Space

In the section above, we argued that a Service Cloud that is blended with Triple
Spaces is an enabler for various types of collaborative activities. To conclude this
section, we shortly present the principle of service federations. Service federations
are grounded in the idea of autonomous and self-conﬁgurable service compositions
in the space. Similar to agents on a blackboard [9], or the processes in Linda, service
are coordinated in the space, and as such create loosely-coupled service composi-
tions without the need for choreographies or man-made orchestrations. This opens
up new frontiers for the automatic creation of complex, but self-organized work-
ﬂows. To a given degree, the control ﬂow is implicitly implied by the data ﬂow,
which, in turn, is not centrally managed, but rather implied by the publish and read
operations on the space that are triggered by individual services.

A related effort, on a much smaller scale than the Service Web, is realized by
a Triple Space-based platform called Sedvice [22]. The core idea of the Sedvice is
to establish a Semantic Web vision in form of shared, but localized and potentially
personalized spaces. This view is based on the argument that the Semantic Web
is characterized by dynamicity and monotonicity of information, and the fact that
the meaning of knowledge is depending upon the locality, the use and the user.
A space in Sedvice is a virtual closed world in the scope of which information is
perceived according to a common context. The primary goal of Sedvice is to enable
control-ﬂow free interaction mechanisms for distributed agents running on mobile
and personal devices. Through Sedvice, it becomes much easier to create innovative
and previously unforeseen mobile applications, as various distributed functionalities
can be coordinated on the ﬂy.

10.3 Illustration by a Larger Example

In this section, we showcase the various uses of the Triple Space in the context of
integration with the Semantic Web Service Execution Environment WSMX. The
technical foundations for the example were given in Sect. 10.2.5. The example is
based on a generic “Virtual Travel Agency” scenario. The travel agency serves a
broker between passengers and different airlines and train services. Passengers can

10.3

Illustration by a Larger Example

243

choose a carrier and specify the departure location and destination of their trip. This
information is taken as input for the travel agency service to discover the online
booking service of the chosen carrier and to book the trip on behalf of the user. In
the given example, the virtual travel agency integrates the booking services of two
airlines and one railway company, namely United Airlines, Austrian Airways, and
Austrian National Railways.

The showcase scenario is realized on top of the integrated WSMX/Triple Space

platform and comprises four steps:

1. WSMX accesses ontologies and service descriptions through the Resource Man-

ager. The Resource Manager retrieves these data from the Triple Space.

2. The user invokes WSMX and speciﬁes the source, destination and carrier for the
trip. The request is sent to WSMX via the external communication grounding.
3. In order for the client request to be processed, there is a need for multiple WSMX
components to interact. The coordination of these interactions is performed via
the Triple Space.

4. After the discovery of a suitable booking service, WSMX interacts with the ser-

vice and returns the result to the client.

Accessing Data Upon start-up of a WSMX instance, the Resource Manager re-
trieves the known ontologies and service descriptions from memory. The Triple
Space-enabled Resource Manager reads these resources non-destructively from the
its storage space. While the data in the space is available in RDF only, the WSMX
runtime operates upon Java objects that represent the WSML language constructs.
The Resource Manager must therefore not only query all the known resources from
the space, but also transform them from RDF into the wsmo4j object model. wsmo4j
is an API and a reference implementation for building Semantic Web Services appli-
cations based on the Web Service Modeling Ontology (WSMO).5 The two listings
(Listings 10.1 and 10.2) depict the semantic description of the OEBB service in
RDF and WSML, respectively.

Invoking WSMX Based on user input about travel start and destination, the vir-
tual travel agency application creates a goal. As we know, a goal in the context of
Semantic Web Services is the formal speciﬁcation of the objective (tasks or activ-
ities) that a user likes to have performed and for which fulﬁllment is sought. In
other words, the goal is an implicit description of the service or services that have
to be executed in order to satisfy the desired request. In order to discover the re-
quired service(s), the virtual travel agency sends the goal to WSMX by invoking the
achieveGoal() operation on the client entry point to WSMX. For this second step of
the example, WSMX serves as a magical black box that matches the goal descrip-
tion to one of the three reservation and booking services, invokes the best match, and
returns the execution result to the client application, i.e., the virtual travel agency.

Listing 10.3 depicts an excerpt of a goal description that in a very simpliﬁed man-
ner states that the request (input data) must be of type OEBBTrip, and the response

5wsmo4j: http://wsmo4j.sourceforge.net/.

244

10 Triple Space Computing for Semantic Web Services

Listing 10.1 OEBB Web
service in WSML

Listing 10.2 OEBB Web
service in RDF

(cid:3)

(cid:5)

(cid:3)

(cid:2)
webService oebb
capability OEBB
postcondition OEBBPostCondition
deﬁnedBy
?request memberOf trip#OEBBTrip.

interface OEBBInterface
choreography OEBBChoreography
stateSignature OEBBStatesignature
importsOntology {trip#tripOntology}

in trip#OEBBTrip withGrounding {
_"http://tripcom.org/services/
oebb.wsdl#tswsdl.
interfaceMessageReference(
OEBBPortType/bookTrip/
bookTripRequest)"}
out trip#Reservation

transitionRules OEBBTransitionRules
forall

{?request} with

(?request memberOf trip#OEBBTrip) do
add(_#1 memberOf trip#Reservation)

endForall
(cid:4)

(cid:2)
<rdf :RDF xmlns="http://example.org/"
<wsmo4rdf_wsml:webService

rdf :about="http://example.org/oebb">

<wsmo4rdf_wsml:hasCapability>
<wsmo4rdf_wsml:hasPostcondition>
<rdf :Description rdf :about=
" http://example.org/OEBBPostCondition">
<rdfs:isDeﬁnedBy>?request memberOf
_"http://trip.example.org/OEBBTrip".
</rdfs :isDeﬁnedBy>
</ rdf :Description>
</wsmo4rdf_wsml:hasPostcondition>
</wsmo4rdf_wsml:Capability>
<wsmo4rdf_wsml:Interface rdf:about=
" http://example.org/OEBBInterface">
<wsmo4rdf_wsml:Choreography>
<rdf :Description rdf :about=
" http://example.org/OEBBChoreography">
...
</ rdf :Description>
</wsmo4rdf_wsml:Choreography>
...

</wsml4rdf_wsml:Choreography>
(cid:4)

(cid:5)

should be of type Reservation. The instance shown in the same listing is the instanti-
ation of the ?request variable in the goal description, and thus speciﬁes the exact trip
details that are sought. This goal description is transformed to RDF, analogously as
in the ‘Accessing data’ step, and then published in a space from which the WSMX
entry point process reads requests. The ‘achieveGoal’ operation is thus mapped to a
series of Triple Space primitives, as it was shown in Sect. 10.2.5.3 for the Resource
Manager operations. Once the goal description is discovered in the Triple Space by
some idle entry point process, WSMX takes care of processing the user request.

10.3

Illustration by a Larger Example

Listing 10.3 Excerpt of the
goal description

(cid:2)
namespace { trip _"http://trip.example.org/" }

245

(cid:3)

Listing 10.4 Excerpt of a
WSMX response

goal tripGoalOEBB

importsOntology { trip#tripOntology }
capability bookTripOEBBCapability
precondition bookTripOEBBPreCondition

deﬁnedBy ?request memberOf trip#OEBBTrip.

postcondition bookTripOEBBPostCondition

deﬁnedBy

?response memberOf q0#Reservation.

ontology TripOEBB

importsOntology { trip#tripOntology }
instance TripViennaInnsbruck
memberOf trip#OEBBTrip

trip#from hasValue "Vienna"
trip#to hasValue "Innsbruck"

(cid:4)

(cid:2)
namespace { trip _"http://trip.example.org/" }

ontology _"http://www.wsmo.org/ontologies/

resp366428579644871840"

instance Reservation341a696a49d34739

memberOf trip#Reservation

trip#from hasValue "Vienna"
trip#to hasValue "Innsbruck"
trip#carrier hasValue "OEBB"
trip#reservationNumber

hasValue "BF082AE24B0B463A"

(cid:4)

(cid:5)

(cid:3)

(cid:5)

Listing 10.4 shows an excerpt of the response that WSMX delivers to the virtual
travel agency application. The response contains an instance of type Reservation, as
it was indicated by the goal description. This instantiation states that WSMX suc-
cessfully booked a trip on behalf of the virtual travel agency, and that there is now
a seat reserved for the client in an OEBB train from Vienna to Innsbruck with the
reservation number “BF082AE24B0B463A”.

Coordination of WSMX Components Upon reception of a goal, WSMX takes
care of processing the user request. This requires cooperation of various compo-
nents, and thus the exchange of events. Components that have fulﬁlled their task
are invoking other components by publishing event-related data in the Triple Space
that is used for component coordination. Components that are idle, and that are thus
waiting for events, query the space for events that match their “signature”. In or-
der to ensure that no two components could process the same request, events are
read destructively, i.e., components make sure, while reading, that no other com-
ponent with the same functionalities would also pick up the information. This is
especially important in settings were particular WSMX components are replicated
in order to increase the performance and responsiveness of the semantic execution
environment.

Listing 10.5 shows an event in RDF that is published by the invoker component
and targeted to the choreography component. The event indicates the target of the

246
(cid:2)
<?xml version="1.0"?>
<rdf :RDF xmlns:rdf="http://www.w3.org/1999/02/22−rdf−syntax−ns#">
<rdf :Description rdf :about="http://tripcom.org/wsmx/bd863e04−180e−4a84−9a31−75843510d04d">

10 Triple Space Computing for Semantic Web Services

<type xmlns="http://tripcom.org/wsmx/">CHOREOGRAPHY</type>
<context xmlns="http://tripcom.org/wsmx/">achieveGoal1</context>
<event xmlns="http://tripcom.org/wsmx/">06df500a−f168−4d54−9298−cb509d517706</event>

</ rdf :Description>
</ rdf :RDF>
(cid:4)

Listing 10.5 Coordination of the invoker and the choreography components

(cid:3)

(cid:5)

event, “CHOREOGRAPHY”, the operation concerned as context of the event and
a unique event identiﬁer. Similarly, a user request is passed between various other
components until a service or the services are discovered that allow WSMX to react
appropriately to the submitted goal.

Once WSMX has terminated the discovery, ranking and possible composition
task, it can invoke the necessary service(s). This invocation is subject to the last step
that is described below.

Invocation of External Service As stated above, after having discovered a suit-
able Web service, the WSMX invoker takes care of invoking the external service
on behalf of the client. As the example services all rely on SOAP messaging, the
invoker wraps the service invocation data in a SOAP/RDF graph. The graph is pub-
lished into a Triple Space that is under observation of the Web service implemen-
tation. The service implementation has to be altered in terms of the communication
interface, not however, in terms of service implementation. Instead of receiving a
SOAP/XML message, the service has to read a SOAP/RDF graph. An excerpt of
one such graph is shown in Listing 10.6. This set of triples is published to the Triple
Space by the invoker as request message to the Web service.

Upon processing of the request, the Web service puts together a response SOAP
message which is again serialized as RDF graph in form of a SOAP/RDF construct.
An example response for the booking service example is shown in Listing 10.7.
Note that the body of the actual SOAP message is not transformed into RDF but
shipped as RDF Literal and thus object value to the <soapts#content> predicate.
Prior to delivering the response to the client, WSMX has to extract the booking
information from the SOAP/RDF message. From the response in Listing 10.7, we
can read that the achieved booking provides the client with a OEBB ticket from
Vienna to Innsbruck, as was desired.

Together with the results presented in the course of the ﬁrst three steps, we can
now describe the whole service invocation process over WSMX by means of com-
munication steps over the Triple Space. In particular, comparing the output of Step 2
(Listing 10.4) with the SOAP/RDF message of Listing 10.7 shows nicely how the
actual Web service world is matched to the semantic world of WSMX.

10.4 Summary

Listing 10.6 Excerpt of the
goal description

Listing 10.7 Excerpt of a
WSMX response

247

(cid:2)
<soapts#urn:uuid:9F125EEF...>
<soapts#type> "soapts#soapMessage" .
<soapts#mep> "http://www.w3.org/ns/wsdl/in−out" .
<soapts#relationship> "soapts#request" .
<soapts#correlationId> "" .
<soapts#destination> "tsc://localhost:8080/OEBB/

(cid:3)

OEBB" .

<soapts#action> "urn:bookTrip" .
<soapts#serviceName> "OEBB" .
<soapts#bindingVersion> "1.0" .
<soapts#isFault> "false" .
<soapts#messageId> "urn:uuid:9

F125EEF34D3A411DF1237742241441" .

<soapts#unprocessable> "false".
<soapts#contentType> "application/soap+xml" .
<soapts#content> "<?xml version=’1.0’ encoding=’
utf−8’?><soapenv:Envelope xmlns:soapenv
="http://schemas.xmlsoap.org/soap/envelope
/"><soapenv:Body><tns:tripxmlns:tns="d45
"><tns:from>Vienna</tns:from><tns:to>
Innsbruck</tns:to></tns:trip></soapenv:Body
></soapenv:Envelope>"

(cid:4)

(cid:2)
<soapts#urn:uuid:3E7BEBF1...> <soapts#type> "

soapts#soapMessage" .

<soapts#mep> "http://www.w3.org/ns/wsdl/in−out" .
<soapts#bindingVersion> "1.0" .
<soapts#destination> "tsc://localhost:8080/OEBB" .
<soapts#action> "urn:bookTripResponse" .
<soapts#unprocessable> "false" .
<soapts#isFault> "false" .
<soapts#messageId> "3

E7BEBF1BA3D41858833ABD5784D52B8" .

<soapts#relationship> "soapts#response" .
<soapts#correlationId> "urn:uuid:9

F125EEF34D3A411DF1237742241441" .

<soapts#contentType> "application/soap+xml" .
<soapts#content> "<?xml version=’1.0’ encoding=’
utf−8’?><soapenv:Envelope xmlns:soapenv
="http://schemas.xmlsoap.org/soap/envelope
/"><soapenv:Body><tns:reservationxmlns:
tns="http://tripcom.org/ns/d45"><tns:from>
Vienna</tns:from><tns:to>Innsbruck</tns:to
><tns:reservationNumber>
BF082AE24B0B463A</tns:
reservationNumber><tns:carrier>OEBB</tns:
carrier></tns:reservation></soapenv:Body></
soapenv:Envelope>".

(cid:4)

(cid:5)

(cid:3)

(cid:5)

10.4 Summary

In summary, this example shows nicely how a Triple Space provides a platform
for asynchronous communication and coordination of Semantic Web Services and
WSMX components. It moreover gives an example of how the Triple Space can
transparently integrate with existing technologies and tools, and how space-based
approaches limit the storage needs and maintenance redundancy of semantic artefact
in the context of WSMX, but also on a much more general basis.

248

10 Triple Space Computing for Semantic Web Services

References

1. Brickley, D., Guha, R.V.: RDF Vocabulary Description Language 1.0: Rdf Schema. W3C

Recommendation (2004)

2. Cabri, G., Leonardi, L., Zambonelli, F.: MARS: a programmable coordination architecture for

mobile agents. IEEE Internet Computing 4(4), 26–35 (2000)

3. Carroll, J.J., Bizer, C., Hayes, P., Stickler, P.: Named graphs. Journal of Web Semantics 3(4),

247–267 (2005)

4. Carroll, J.J., Bizer, C., Hayes, P., Stickler, P.: Named graphs, provenance and trust. In: 14th

Int. World Wide Web Conference, pp. 613–622. ACM Press, New York (2005)

5. Ciancarini, P., Knoche, A., Tolksdorf, R., Vitali, F.: PageSpace: an architecture to coordinate
distributed applications on the Web. Computer Networks and ISDN Systems 28(7–11), 941–
952 (1996)

6. Ciancarini, P., Tolksdorf, R., Zambonelli, F.: A survey of coordination middleware for XML-

centric applications. Knowledge Engineering Review 17(4), 389–405 (2002)

7. de Bruijn, J., Lausen, H., Polleres, A., Fensel, D.: The Web service modeling language WSML:

an overview. In: 3rd European Semantic Web Conference, pp. 590–604 (2006)

8. De Francisco Marcos, D., Toro Del Valle, G., Nixon, L.: Towards a multimedia content mar-
ketplace implementation based on triplespaces. In: 7th Int. Semantic Web Conference, pp.
875–888 (2008)

9. Engelmore, R.: Blackboard Systems. Addison-Wesley, Reading (1988)
10. Eugster, P.T., Felber, P.A., Guerraoui, R., Kermarrec, A.-M.: The many faces of publish/sub-

scribe. ACM Computing Surveys 35(2), 114–131 (2003)

11. Fensel, D.: Triple-space computing: semantic Web services based on persistent publication of
information. In: IFIP Int. Conference on Intelligence in Communication Systems, pp. 43–53
(2004)

12. Fensel, D., Krummenacher, R., Shaﬁq, O., Kuehn, E., Riemer, J., Ding, Y., Draxler, B.: TSC—
triple space computing. E&I. Elektrotechnik und Informationstechnik 124(1/2), 31–38 (2007)
13. Fielding, R.T.: Architectural styles and the design of network-based software architectures.

Ph.D. thesis, University of California, Irvine (2000)

14. Fielding, R.T., Taylor, R.N.: Principled design of the modern Web architecture. ACM Trans-

actions on Internet Technology 2(2), 115–150 (2002)

15. Franklin, M., Halevy, A., Maier, D.: From databases to dataspaces: a new abstraction for

information management. SIGMOD Record 34(4), 27–33 (2005)

16. Gelernter, D.: Generative communication in Linda. ACM Transactions on Programming Lan-

guages and Systems 7(1), 80–112 (1985)

17. Klyne, G., Carroll, J.J.: Resource Description Framework (RDF): concepts and abstract syn-

tax. W3C Recommendation (2004)

18. Krummenacher, R., Simperl, E., Fensel, D.: Towards scalable information spaces. In: Work-
shop on New Forms of Reasoning for the Semantic Web: Scaleable, Tolerant and Dynamic,
ISWC (2007)

19. Krummenacher, R., Simperl, E., Cerizza, D., Della Valle, E., Nixon, L., Foxvog, D.: En-
abling the European patient summary through triplespaces. Computer Methods and Programs
in Biomedicine (2009)

20. McGuinness, D.L., van Harmelen, F.: OWL Web Ontology Language overview. W3C Rec-

ommendation (2004)

21. Mocan, A., Moran, M., Cimpian, E., Zaremba, M.: Filling the gap—extending service oriented
architectures with semantics. In: IEEE Int. Conference on e-Business Engineering, pp. 594–
601 (2006)

22. Oliver, I., Honkola, J., Ziegler, J.: Dynamic, localised space based semantic Webs. In: IADIS

Int. WWW/Internet Conference, pp. 426–431 (2008)

23. Omicini, A., Zambonelli, F.: Coordination for Internet application development. Autonomous

Agents and Multi-Agent Systems 2(3), 251–269 (1999)

24. Prud’hommeaux, E., Seaborne, A.: SPARQL query language for RDF. W3C Recommendation

(2008)

References

249

25. Simperl, E., Krummenacher, R., Nixon, L.J.B.: A coordination model for triplespace comput-

ing. In: 9th Int. Conference on Coordination Models and Languages, pp. 1–18 (2007)

26. Tolksdorf, R.: Laura—a service-based coordination language. Science of Computer Program-

ming 31(2/3), 359–381 (1998)

27. zur Muehlen, M., Nickerson, J.V., Swenson, K.D.: Developing Web services choreography
standards—the case of REST vs. SOAP. Decision Support Systems 40(1), 9–29 (2005)

Chapter 11
OWL-S and Other Approaches

Abstract WSMO is just one of the frameworks to semantically describe Web ser-
vices that have been developed in the last years. OWL-S and its extension SWSF,
as well as METEOR-S, have proposed alternative approaches to WSMO that, de-
spite sharing some similarities, exhibit signiﬁcant differences with respect to the
technological standards, languages and underlying formalisms that are used. This
chapter gives an overview of these approaches together with a comparison based
on the criteria referring to the core design principles of Web and Semantic Web
development, as well as of distributed, service-oriented computing on the Web. In
addition, the chapter introduces IRS-III, a framework and implementation infras-
tructure that, similarly to WSMX, supports the creation of Semantic Web Services
based on WSMO ontology.

11.1 Motivation

WSMO is just one of the frameworks to semantically describe Web services that
have been developed in the last years. OWL-S and its extension SWSF, as well as
METEOR-S, have proposed alternative approaches to WSMO that, despite shar-
ing some similarities, exhibit signiﬁcant differences with respect to the technolog-
ical standards, languages and underlying formalisms that are used. Moreover, the
WSMO framework has been used and extended by implementation projects such
as IRS-III, in addition to WSMX, which was introduced in Chap. 9. The goal of
this chapter is to explain the main features of the approaches, to overview the tools
supporting the approaches, and to compare the approaches to WSMO in terms of a
set of pre-deﬁned criteria which are introduced in the remainder of this section.

Semantic Web Services are aimed at producing an integrated technology for the
next generation of the Web by combining Semantic Web technologies and Web ser-
vices, thereby turning the Internet from a information repository for human con-
sumption into a worldwide system for distributed Web computing. Therefore, it
comes naturally that in order to achieve these goals a Semantic Web Services frame-
work has to be compliant and integrate the core design principles of the World Wide
Web, of the Semantic Web and of distributed, service-oriented computing on the
Web. These principles are reﬂected by the following set of criteria which will be
used to compare alternative Semantic Web Services frameworks:

D. Fensel et al., Semantic Web Services,
DOI 10.1007/978-3-642-19193-0_11, © Springer-Verlag Berlin Heidelberg 2011

251

252

11 OWL-S and Other Approaches

• Web compliance An approach must support the foundational Web concepts such

as IRIs, namespaces, XML, and decentralization of resources.

• Ontological foundation Ontologies must be used as the data model of an ap-

proach.

• Strict decoupling Resources of an approach such as ontologies, Semantic Web

Service descriptions, goals and mediators must be deﬁned in isolation.

• Centrality of mediation Handling of the heterogeneities at various levels (data,
underlying ontology, protocol and process) must be addressed in a comprehensive
fashion by the approach.

• Ontological role separation An approach must employ epistemological differ-

entiation of user desires and service offerings.

• Description vs implementation Description notions used by an approach must
not be bound to the speciﬁc executable technologies, in other words, an approach
should enable grounding to various implementations.

• Execution semantics An approach should support the deﬁnition of formal exe-

cution semantics of a reference implementation.

• Service vs Web service separation An approach should make distinction be-
tween the service as a computational entity (i.e., the Web service) and actual
value provided (i.e., the service).

11.2 OWL-S

OWL-S [12], formerly known as DAML-S, is an ontology for the description of
Semantic Web Services expressed in the Web Ontology Language (OWL) [13].
OWL-S deﬁnes an upper ontology for services with three major elements (see
Fig. 11.1 from [12]):
• Service Proﬁle which describes what the service does in terms of inputs, outputs,

preconditions, and effects (IOPEs).

• Service Grounding which describes how the service can be accessed, usually by

grounding to WSDL.

• Service Model which describes how the service works in terms of a process

model that may describe a complex behavior over underlying services.

The service serves as an organizational point of reference for describing Web
services; every service is declared by creating an instance of the service concept.
Listing 11.11 shows a ﬁctitious airline service called BravoAir.

11.2.1 Service Proﬁle

In OWL-S, the service proﬁle describes the intended purpose of the service from
the perspective of the provider and of the requester. The service proﬁle is designed

1Listing taken from http://www.daml.org/services/owl-s/1.1/examples.html.

11.2 OWL-S

Fig. 11.1 OWL-S service
ontology

253

<rdf:RDF>

<owl:Ontology rdf:about="">

<rdfs:comment>

This ontology represents the OWL−S service description for the BravoAir Web service example.

</rdfs:comment>
<owl:imports rdf:resource="http://www.daml.org/services/owl−s/1.0/Service.owl"/>
<owl:imports rdf:resource="http://www.daml.org/services/owl−s/1.0/BravoAirProﬁle.owl"/>
<owl:imports rdf:resource="http://www.daml.org/services/owl−s/1.0/BravoAirProcess.owl"/>

</owl:Ontology>

<service:Service rdf:ID ="BravoAir_ReservationAgent">

<!−− ReferencetotheBravoAirProﬁle −−>
<service:presents rdf:resource=" http: // www.daml.org/services/owl−s/1.0/BravoAirProﬁle.owl#

Proﬁle_BravoAir_ReservationAgent"/>
<!−− ReferencetotheBravoAirProcessModel −−>
<service:describedBy rdf:resource="http: // www.daml.org/services/owl−s/1.0/BravoAirProcess.owl#

BravoAir_ReservationAgent_ProcessModel"/>

<!−− ReferencetotheBravoAirGrounding −−>
<service:supports rdf:resource=" http: // www.daml.org/services/owl−s/1.0/BravoAirGrounding.owl#

Grounding_BravoAir_ReservationAgent"/>

</service:Service>

</rdf:RDF>

Listing 11.1 BravoAir service instance

to accommodate requirements of a service-seeking agent to determine whether the
service fulﬁlls user needs. In order to offer rich modeling capabilities to capture
what is accomplished by the service, limitations on service applicability and qual-
ity of service, the service proﬁle is further decomposed as presented in Fig. 11.2
from [12].

Through the service proﬁle, users are able to represent functional capabilities of a
service, related provider information, and features that specify characteristics of the
service regardless of its actual representation. The ability to use OWL sub-classes
makes it possible to create specializations of a service representation.

The provider information part of the service proﬁle, for instance, aspects such
as (serviceName, textDescription, and serviceProduct, yields a human-readable de-
scription of the service and its offering, as well as contact information pointing to
the service provider (e.g., the service maintenance operator and the customer repre-
sentative)).

254

11 OWL-S and Other Approaches

Fig. 11.2 OWL-S service proﬁle

The functional description part captures the transformation produced by the
service, that is, the required inputs (Input) and the generated outputs (Output). Ad-
ditionally, the execution of the service might be constrained by some external con-
ditions (Condition) and have effects (Result) that change these conditions.

Finally, the description of a host of properties part of the service proﬁle cov-
ers the service category (ServiceCategory), quality ratings of the service and an
unbounded list of service parameters that can contain any type of information (for
instance, an estimate of the maximum response time, the geographical availability
of the service), given as ServiceParameter.

Listing 11.2 gives a Service Proﬁle example of the BravoAir airline site.2

11.2.2 Service Grounding

The service grounding speciﬁes how the abstract service representations (namely,
Service Proﬁle and Service Model) are mapped to the concrete service description
elements required for interacting with the service (inputs and outputs of an atomic
processes). In this sense, atomic processes represent service communication primi-
tives. In contrast, concrete messages sent to, and received from the concrete service
are speciﬁed explicitly in a Service Grounding.

Though initially based on the Web Service Description Language (WSDL),
OWL-S does not impose any constraints on the choice of a grounding mecha-
nism. The complementary strengths of these two speciﬁcation languages allow a

2Listing taken from http://www.daml.org/services/owl-s/1.1/examples.html.

11.2 OWL-S

<rdf:RDF>

255

<owl:Ontology rdf:about="">

<rdfs:comment>BravoAir Example for OWL−S Proﬁle description</rdfs:comment>
<owl:imports rdf:resource="http://www.daml.org/services/owl−s/1.0/Service.owl"/>
...

</owl:Ontology>
<proﬁle:serviceParameter>

<addParam:GeographicRadius rdf:ID="BravoAir−geographicRadius">

<proﬁle:serviceParameterName>BravoAir Geographic Radius</proﬁle:serviceParameterName>
<proﬁle:sParameter rdf:resource="http://www.daml.org/services/owl−
s /1.0/ Country.owl#UnitedStates"/>

</addParam:GeographicRadius>

</proﬁle:serviceParameter>

<proﬁle:serviceCategory>

<addParam:NAICS rdf:ID="NAICS−category">

< proﬁle:value > Airline reservation services </ proﬁle:value >
<proﬁle:code>561599</proﬁle:code>

</addParam:NAICS>
</proﬁle:serviceCategory>
...
< proﬁle:hasInput rdf:resource="http://www.daml.org/services/owl−s/1.0/BravoAirProcess.owl#

DepartureAirport_In"/>

<proﬁle:hasOutput rdf:resource="http://www.daml.org/services/owl−s/1.0/BravoAirProcess.owl#

AvailableFlightItineraryList_Out"/>

</rdf:RDF>

Listing 11.2 BravoAir service proﬁle

Fig. 11.3 OWL-S service
grounding

service developer to beneﬁt from using both OWL-S’ process model and class typ-
ing features—as opposed to what XML Schema provides—and to reuse standard-
ized approaches and software support for message exchange related to WSDL.

The WSDL/OWL-S grounding is based on a set of correspondences between the

two speciﬁcations, as presented in Fig. 11.3 introduced in [12].
• An OWL-S atomic process corresponds to a WSDL (v1.1) operation.
• Inputs and outputs of an OWL-S atomic process correspond to a WSDL message.
• Input and output types of an OWL-S atomic process correspond to the WSDL’s
extensible notion of abstract type (and can be used in WSDL message-part spec-
iﬁcations).

256

11 OWL-S and Other Approaches

Listing 11.33 gives an overview of the OWL-S BravoAir Service Grounding. The
listing covers only the WSDL-based grounding deﬁnition of the GetDesiredFlight-
Details atomic process.

11.2.3 Service Model

OWL-S deﬁnes an interaction with a service in the form of a process. The notion
of a process is represented by the OWL-S v1.1 class Process, which is conceived
as a sub-class of the class ServiceModel. The purpose of a process is twofold: it
generates and returns some information as a function of the information given and
the current world state described by the inputs and outputs of the process, and it can
produce a change in the world, captured through the preconditions and effects of the
process.

A process represents a speciﬁcation of the approaches a client may use to in-
teract with a service. OWL-S distinguishes between three classes of processes, as
presented in Fig. 11.4 [12]:
• Atomic processes which represent directly invocable computational entities.
They are executed in a single step and cannot be further reﬁned. An atomic pro-
cess takes an input message, and returns output message. Additionally, atomic
processes have an associated grounding which enables a service requester to con-
struct input and de-construct output messages depending on the concrete service
speciﬁcation and communication language in use.

• Simple processes which, similarly to atomic processes, are conceived as having
single-step executions, but do not have associated grounding and are not invoca-
ble. The simple processes are used as elements of abstraction, offering a special-
ized way to use an atomic process, or to simplify the representation of a composite
process for planning and reasoning purposes.

• Composite processes which represent more complex processes decomposable
into other (composite or non-composite) processes. The decomposition is deﬁned
in terms of control constructs such as sequence and if-then-else (see below). An
composite process describes a behavior the client can enact by sending and re-
ceiving a set of messages.

For deﬁning composite processes, OWL-S supports the following control struc-

tures:
• Sequence which is the most basic control construct deﬁning a list of components

that must me done in speciﬁed order.

• Split components represent process components determined for a concurrent ex-

ecution.

• Split + Join which, similarly to split, deﬁnes a bag of components that are meant

to be executed in parallel but with a precise synchronization point.

3Listing taken from http://www.daml.org/services/owl-s/1.1/examples.html.

11.2 OWL-S

<rdf:RDF>

257

<owl:Ontology rdf:about="">

<owl:imports rdf:resource="http://www.daml.org/services/owl−s/1.0/Service.owl" />
<owl:imports rdf:resource="http://www.daml.org/services/owl−s/1.0/Grounding.owl" />
<owl:imports rdf:resource="http://www.daml.org/services/owl−s/1.0/BravoAirService.owl" />
<owl:imports rdf:resource="http://www.daml.org/services/owl−s/1.0/BravoAirProcess.owl" />

</owl:Ontology>

<grounding:WsdlGrounding

rdf:ID ="Grounding_BravoAir_ReservationAgent">
<service:supportedBy rdf:resource="&ba_service;#BravoAir_ReservationAgent"/>
<!−− Collectonofall the groundingsspeciﬁcations −−>
<grounding:hasAtomicProcessGrounding rdf:resource="#WsdlGrounding_GetDesiredFlightDetails"/>
<grounding:hasAtomicProcessGrounding rdf:resource="#WsdlGrounding_SelectAvailableFlight"/>
<grounding:hasAtomicProcessGrounding rdf:resource="#WsdlGrounding_LogIn"/>
<grounding:hasAtomicProcessGrounding rdf:resource="#WsdlGrounding_ConﬁrmReservation"/>

</grounding:WsdlGrounding>

<grounding:WsdlAtomicProcessGrounding rdf:ID="WsdlGrounding_GetDesiredFlightDetails">

<!−− GroundingfortheAtomicProcessGetDesiredFlightDetails −−>
<grounding:owlsProcess rdf:resource="&ba_process;#GetDesiredFlightDetails"/>
<!−− ReferencetothecorrespondingWSDLoperation −−>
<grounding:wsdlOperation rdf:resource="#GetDesiredFlightDetails_operation"/>

<!−− ReferencetotheWSDLinputmessage −−>
<grounding:wsdlInputMessage>

<xsd:anyURI rdf:value="&BravoAirGroundingWSDL;#GetDesiredFlightDetails_Input"/>

</grounding:wsdlInputMessage>

<!−− MappingofOWL−SinputstoWSDLmessageparts −−>
<grounding:wsdlInputs rdf:parseType="Collection">

<grounding:WsdlInputMessageMap>

<grounding:owlsParameter rdf:resource="&ba_process;#departureAirport_In"/>
<grounding:wsdlMessagePart>

<xsd:anyURI rdf:value="&BravoAirGroundingWSDL;#departureAirport"/>

</grounding:wsdlMessagePart>
</grounding:WsdlInputMessageMap>
<grounding:WsdlInputMessageMap>

<grounding:owlsParameter rdf:resource="&ba_process;#arrivalAirport_In"/>
<grounding:wsdlMessagePart>

<xsd:anyURI rdf:value="&BravoAirGroundingWSDL;#arrivalAirport"/>

</grounding:wsdlMessagePart>
</grounding:WsdlInputMessageMap>
<grounding:WsdlInputMessageMap>

<grounding:owlsParameter rdf:resource="&ba_process;#outboundDate_In"/>
<grounding:wsdlMessagePart>

<xsd:anyURI rdf:value="&BravoAirGroundingWSDL;#outboundDate"/>

</grounding:wsdlMessagePart>
</grounding:WsdlInputMessageMap>
<grounding:WsdlInputMessageMap>

<grounding:owlsParameter rdf:resource="&ba_process;#inboundDate_In"/>
<grounding:wsdlMessagePart>

<xsd:anyURI rdf:value="&BravoAirGroundingWSDL;#inboundDate"/>

</grounding:wsdlMessagePart>
</grounding:WsdlInputMessageMap>
<grounding:WsdlInputMessageMap>

<grounding:owlsParameter rdf:resource="&ba_process;#roundTrip_In"/>
<grounding:wsdlMessagePart>

<xsd:anyURI rdf:value="&BravoAirGroundingWSDL;#roundTrip"/>

</grounding:wsdlMessagePart>
</grounding:WsdlInputMessageMap>

</grounding:wsdlInputs>
<grounding:wsdlReference>

Listing 11.3 BravoAir service grounding

258

11 OWL-S and Other Approaches

<xsd:anyURI rdf:value="http: // www.w3.org/TR/2001/NOTE−wsdl−20010315"/>

</grounding:wsdlReference>

</grounding:WsdlAtomicProcessGrounding>

<grounding:WsdlOperationRef rdf:ID="GetDesiredFlightDetails_operation">

<rdfs:comment>
A pointer to the WSDL operation used for GetDesiredFlightDetails
</rdfs:comment>
<!−− locateporttypeto beused −−>
<grounding:portType>

<xsd:anyURI rdf:value="&BravoAirGroundingWSDL;#GetDesiredFlightDetails_PortType"/>

</grounding:portType>
<!−− locateoperationtobeused −−>
<grounding:operation>

<xsd:anyURI rdf:value="&BravoAirGroundingWSDL;#GetDesiredFlightDetails_operation"/>

</grounding:operation>

</grounding:WsdlOperationRef>
...

</rdf:RDF>

Listing 11.3 (Continued)

Fig. 11.4 OWL-S service model

11.2 OWL-S

259

• Any-Order construct does not prescribe the execution order but does not allow

concurrent execution (neither interleaving, nor overlapping).

• Choice speciﬁes any of the control constructs that may be chosen for execution

from the given bag of components (given by the component’s property).

• If-Then-Else constructs have the same semantics as in the modern programming
languages—test if the condition holds and execute construct associated to the
then part; otherwise execute the one associated to the else part. The condition is
viewed as a logical expression.

• Iterate enables repetitive execution of a component without any assumption
about the number of iterations, repetition initiation, resumption and termination.
• Repeat-While and Repeat-Until deﬁne the repetition which is constrained, as
opposed to the previous construct, by the logical expression represented as a con-
dition. The difference between the two constructs follows the well-known pro-
gramming language conventions.

Listing 11.44 represents the OWL-S BravoAir Service Model. The BravoAir pro-
cess represents a composite process consisting of a sequence of GetDesiredFlight-
Details, SelectAvailableFlight and BookFlight, where the latter is itself a composite
process consisting of the Login and ConﬁrmReservation atomic processes.

11.2.4 An Extension to OWL-S

Semantic Web Services Framework (SWSF) [3] has its roots in OWL-S and the ISO
18629 Process Speciﬁcation Language (PSL) [8]. It has been developed with an aim
to overcome deﬁciencies of OWL-S, namely:
• To provide means to overcome the restricted expressivity of Description Logics.
• To provide formal deﬁnitions of the semantic aspects of conditions and the dy-

namic aspects of Semantic Web Services by relying on PSL.

• Providing a single semantic language framework.

Two major components comprise SWSF: the conceptual model Semantic Web Ser-
vice Ontology (SWSO), and the family of knowledge representation languages Se-
mantic Web Service Language (SWSL). SWSO inherits the three major OWL-S
elements—proﬁles, grounding and service model, further extended and reﬁned in
terms of a more expressive underlying language (SWSL) and a richer behavioral
process model (based on PSL). Two independent formalizations of the conceptual
model are available:
• FLOWS (First-order Logic Ontology for Web Services) which relies on the

semantics of the SWSL-FOL language, and

• ROWS (Rule Ontology for Web Services) which uses the semantics of the

SWSL-Rules language.

4Listing taken from http://www.daml.org/services/owl-s/1.1/examples.html.

260

<rdf:RDF>

11 OWL-S and Other Approaches

<process:ProcessModel rdf:ID="BravoAir_ReservationAgent_ProcessModel">

<process:hasProcess rdf:resource="#BravoAir_Process"/>
<service:describes rdf:resource="http://www.daml.org/services/owl−

s /1.0/ BravoAirService.owl#BravoAir_ReservationAgent"/>

</process:ProcessModel>

<process:CompositeProcess rdf:ID="BravoAir_Process">

<process:composedOf>
<process:Sequence>

<process:components rdf:parseType="Collection">

<process:AtomicProcess rdf:about="#GetDesiredFlightDetails"/>
<process:AtomicProcess rdf:about="#SelectAvailableFlight"/>
<process:CompositeProcess rdf:about="#BookFlight"/>

</process:components>

</process:Sequence>
</process:composedOf>
</process:CompositeProcess>
<process:CompositeProcess rdf:ID="BookFlight">

<process:composedOf>
<process:Sequence>

<process:components rdf:parseType="Collection">
<process:AtomicProcess rdf:about="#Login"/>
<process:AtomicProcess rdf:about="#ConﬁrmReservation"/>

</process:components>

</process:Sequence>
</process:composedOf>
</process:CompositeProcess>

<process:AtomicProcess rdf:ID="LogIn">

<process:hasInput rdf:resource="#AcctName_In"/>
<process:hasInput rdf:resource="#Password_In"/>

</process:AtomicProcess>

<process:Input rdf:ID="AcctName_In">

<process:parameterType rdf:resource="http://www.daml.org/services/owl−s/1.0/Concepts.owl#AcctName"/>

</process:Input>

<process:Input rdf:ID="Password_In">

<process:parameterType rdf:resource="http://www.daml.org/services/owl−s/1.0/Concepts.owl#Password"/>

</process:Input>

</rdf:RDF>

Listing 11.4 BravoAir service model

The PSL-based description of the service behavior introduces two fundamental ex-
tensions: a structured notion of the atomic process, and an infrastructure for speci-
fying various forms of data ﬂow.

The SWSL family of languages is compliant with the Web principles through
the usage of IRIs, the integration of XML built-in types and XML namespaces, as
well as import mechanisms. The languages are designed in layers, with increased
modeling power. Just like in WSMO, SWSL deﬁnes two major variants:

• SWSL-First-order Logic which is grounded in ﬁrst-order logic including HiLog

and F-Logic, and

• SWSL-Rules representing a Logic Programming language introduced to support
service-related tasks such as discovery, contracting and policy speciﬁcation.

11.2 OWL-S

11.2.5 Tool Support

261

Rather than deﬁning and implementing an architecture for fully-ﬂedged tool support
of Semantic Web Services using OWL-S, as has been the aim of SESA and WSMX,
the community has produced a number of tools that play different roles. Here we
are using the SESA architecture as the basis to survey and compare them.

11.2.5.1 Reasoning

OWL-S is an OWL ontology like any other, therefore reasoning support is provided
primarily by OWL reasoners. OWL itself distinguishes among three variants of in-
creasing expressivity: OWL-Lite, OWL-DL and OWL-Full. OWL-Full has no de-
cidable reasoning and OWL-Lite provides support for only simple constraints over
classiﬁcation hierarchies, therefore reasoner implementation concentrates on OWL-
DL which is based in description logics. Pellet [22] and FaCT/FaCT++ [27] are two
such OWL-DL reasoners based on tableaux algorithms. Since, however, OWL-DL
is not sufﬁciently expressive in most cases to deﬁne all parts of the user models,
for instance, deﬁning conditions within the process model, an embedding of an-
other rule language such as SWRL,5 or rule-oriented extensions are used for this
purpose [19]. Consequently, reasoners capable of dealing with OWL-DL and rules,
such as RACER [9] and Kaon2 [14] are often utilized. An advantage of the OWL-S
model over WSMO and WSML is that, just as WSMO’s representation in OCML,
the same reasoner can be used to carry out meta-reasoning about the model, and
therefore the meta-model itself can be used in user models.

11.2.5.2 Discovery

The process underlying discovery in OWL-S is usually referred to as matchmaking.
It heavily relies on the explicit speciﬁcation of inputs and outputs. The ontologi-
cal relationships between the inputs and outputs (I/O) of a ‘template’, which in this
sense plays the role of a WSMO goal, but is not explicitly conceptualized as such,
and a candidate service are compared. A set of ﬁve ‘ﬁlters’ classify the structural
relationships that are accepted between the template and candidate I/Os. Klusch
et al. [11] proposes OWLS-MX, a match-maker that implements such an algorithm
and combines it with syntactic matching to cover those cases when semantic match-
making fails—for instance, when two ontologies are disjoint since there is no means
for mediation to map these. The survey in this paper also afﬁrms that there are no
implementations that offer both this I/O-based approach and also consider the pre-
conditions and effects, completing the so-called ‘IOPE’-based matchmaking that
was envisioned for OWL-S. To the knowledge of the authors, there exists no dis-
covery approach for OWL-S that also covers the behavior of a service, since they

5http://www.w3.org/Submission/SWRL.

262

11 OWL-S and Other Approaches

are simply considered to be atomic in the model. A second approach we would like
to highlight is proposed in [24]. It considers the addition of the OWL-S model to
UDDI descriptions and the extension of an open-source UDDI engine, jUDDI, to
support semantic matchmaking based on these descriptions.

11.2.5.3 Choreography and Orchestration

The OWL-S model fundamentally assumes that services are invoked as atomic ac-
tions, and therefore no model of choreography is contained. On the other hand, the
process model allows services to be attached either to an atomic process, which
is usually grounded to a WSDL operation, or to a composite process. The process
model allows for a hierarchical control-ﬂow oriented decomposition of composite
processes, ultimately producing some ordering over atomic processes. When such a
service is to be executed the OWL-S Virtual Machine [19], formerly the DAML-S
Virtual Machine, executes the atomic processes up to completion of the composite
process description, returning the outputs just as if the invocation had been atom-
ically carried out. In evaluating a composite process model, the Virtual Machine
needs access to OWL-DL and SWRL reasoning provided by RACER. In SESA
terms, then the OWL-S Virtual Machine fulﬁlls the basic role of an Orchestration
Engine, but OWL-S has no support from a Choreography Engine.

11.2.5.4 Mediation

The OWL-S model does not provide dedicated support for mediators. Data me-
diation services can, of course, be described using the provision for other ser-
vices. There are two notable approaches considering data mediation explicitly in
OWL-S: Paolucci et al. [20] considers exactly this embedding of WSMO’s media-
tor model into OWL-S, whereas work related with [26] considers mediation services
as ‘shims’, which mix, rather than isolate, the syntactic and semantic representa-
tions of data in order to efﬁciently apply mediation at the syntactic level. Since, as
stated above, the OWL-S model treats services as invoked atomically and without
choreography, there is no notion of automated process mediation in OWL-S. If the
interaction between two services requires process mediation, this must be carried
out as part of a composite process, though the process model has deﬁciencies even
in this regard due to its notion of atomic service interaction [16].

11.2.5.5 Composition

A great deal of work in automated service composition has been carried out in
OWL-S, not least since its abstraction of service interactions to atomic ones, and
its simple model of composite processes are a good ﬁt to existing techniques. Much
work has been carried out using AI planning-based techniques, for instance, result-
ing from [29]. A state-of-the-art tool, which considers the need to apply re-planning
during the execution of a composite service, is described in [10].

11.3 METEOR-S

Table 11.1 OWL-S summary

Compliance Criteria

Comments

263

√

√

√

√

√

Web compliance

Ontology-based

Strict decoupling

Supports URI, namespaces and XML

Based on OWL

Ontologies and services are speciﬁed independently

Centrality of mediation

No support for mediation

Ontological role separation

Doesn’t have the notion of user desires

Description vs. implementation Opened for various grounding

Execution semantics

Doesn’t have the notion of execution semantics

Services vs. Web Services

Designed as a means to describe Web services

11.2.6 OWL-S Summary

Table 11.1 lists the main features of OWL-S compared against the criteria intro-
duced in Sect. 11.1.

11.3 METEOR-S

The METEOR-S project6 covers the complete life cycle of Semantic Web processes
including annotation, discovery, composition and enactments of Web services:

• Semantic annotation of Web services The annotation is supported through the
METEOR-S Web Service Annotation Framework (MWSAF) which builds upon
the Web Service Semantics (WSDL-S) and its successor Semantic Annotations
for WSDL and XML Schema (SAWSDL).

• Semantics-based discovery of Web services The Web service discovery mecha-
nisms are offered through the METEOR-S Web Service Discovery Infrastructure
(MWSDI) which enhances existing Web service discovery infrastructure by using
semantics.

• Composition of Web services The METEOR-S Web Service Composition
Framework (MWSCF) increases the ﬂexibility of the Web services’ composition
through semantic process templates.

The approach is strongly founded on existing Web services standards, incremen-
tally extending them with semantic support—a feature which contrasts with ap-
proaches such as OWL-S or WSMO.

6http://lsdis.cs.uga.edu/projects/meteor-s/.

264

11 OWL-S and Other Approaches

11.3.1 Semantic Annotation of Web services

The METEOR-S project comprises the so-called MWSAF [21], a framework for the
semi-automatic annotation of Web services. These annotations address four differ-
ent aspects of Web services’s semantics. First, MWSAF supports including anno-
tations about the semantics of the inputs and the outputs of Web services. Second,
the annotation framework supports the deﬁnition of functional semantics, i.e., what
the service does. Third, MWSAF allows including execution semantics to support
verifying the correctness of the execution of Web services. At last, the framework
supports including information regarding the quality of service, such as performance
or costs associated to the execution of Web services.

Initial research on the framework was devoted to supporting the semi-automatic
annotation of XML schemas as part of Web services deﬁnitions. This work is based
on the transformation of both XML schemas and ontologies into a common rep-
resentation format called SchemaGraph [21] in order to facilitate the matching be-
tween both models (as presented through the examples shown in Figs. 11.5 and 11.6
due to [21]). Once ontologies and XML schemas are translated into this common
representation, a set of matching algorithms can be applied to (semi-)automatically
enhance the syntactic deﬁnitions with semantic annotations.

In a nutshell, the matching algorithm computes a ‘Match Score’ between each
element of the WSDL SchemaGraph and the Ontology SchemaGraph. This score
takes into account the linguistic and the structural similarity. The best matching
element is chosen by taking into account both the Match Score and the speciﬁcity
of the concepts. Finally, a global matching average is computed to help in selecting
the best overall match between Web services and ontologies. Further details about
the algorithm can be found in [21].

The MWSAF is composed of three main components: an ontology store, the
matcher library and a translator library. The ﬁrst component stores the ontologies
that will be used for annotating the Web services. The matcher library provides
different algorithm implementations for linguistic and structural matching between
concepts and Web services elements. The translator library consists of the programs
used for generating the SchemaGraph representation for ontologies and Web ser-
vices.

The MWSAF assists users in annotating Web services by browsing and comput-
ing the similarity between domain models and Web services elements. The last step
in the annotation process is their representation for future reuse for automated pro-
cessing. To cater for this the METEOR-S project makes use of WSDL-S, which we
present in more detail in the following section.

11.3.1.1 WSDL-S and SAWSDL

WSDL-S was proposed as a member submission to the W3C in November 2005
between the LSDIS Laboratory and IBM [2]. In line with the philosophy of the

11.3 METEOR-S

Fig. 11.5 Mapping of the
XML schema constructs to
the SchemaGraph
representations

265

METEOR-S project, WSDL-S is a lightweight approach to associate semantic an-
notations with Web services using existing Web service standards not related to se-
mantic technologies. Concretely, semantic annotations in the form of URI references
to external models are added to the interface, operation and message constructs in
WSDL. WSDL-S does not impose any restrictions on the knowledge representa-
tion language to be used to deﬁne semantic models. WSML, OWL and UML are
recommended as potential candidates [2].

WSDL-S provides a set of extension attributes and elements for associating se-
mantic annotations to Web services. Through extension attribute modelReference
one can specify associations between a WSDL entity and a concept in a semantic
model. This extension can be used for annotating XML Schema complex types and

266

11 OWL-S and Other Approaches

Fig. 11.6 Mapping of the
ontology representations to
the SchemaGraph elements

elements, WSDL operations and the extension elements precondition and effect,
which are described below.

The schemaMapping extension attribute can be used for specifying mechanisms
for handling structural differences between XML Schema elements and complex
types, and their corresponding semantic model concepts. These annotations can
then be used for what we refer to as lifting and lowering of execution data (i.e.,
transforming syntactic data into its semantic counterpart, and vice versa).

WSDL-S deﬁnes two new child elements for the operation element, namely pre-
condition and effect. These elements allow deﬁning the conditions that must hold
before executing an operation and the effects the execution would have. This infor-
mation is typically to be used for discovering suitable Web services. Finally, WSDL-
S allows using the category extension attribute on the interface element in order to

11.3 METEOR-S

<wsdl:description

267

targetNamespace="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
xmlns=http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#
xmlns:wsdl=http://www.w3.org/ns/wsdl
xmlns:xs=http: // www.w3.org/2001/XMLSchema
xmlns:sawsdl="http://www.w3.org/ns/sawsdl">
<wsdl:types>

<xs:schema targetNamespace=http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#

elementFormDefault="qualiﬁed">

<xs:element name="OrderRequest"

sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#

OrderRequest"

sawsdl:loweringSchemaMapping="http://www.w3.org/2002/ws/sawsdl/spec/mapping/RDFOnt2Request.

xml">
<xs:complexType>
<xs:sequence>

<xs:element name="customerNo" type="xs:integer" />
...

</wsdl:description>

Listing 11.5 An example of a WSDL service description extended with the SAWSDL attributes

deﬁne categorization information for publishing Web services in registries such as
UDDI.

More recently, the WSDL-S proposal has been superseded by SAWSDL [6]
which is a W3C Recommendation. SAWSDL is a restricted and homogenized ver-
sion of WSDL-S in which annotations such as preconditions and effects have not
been explicitly contemplated since there is no current agreement about them in the
Semantic Web Services community. It is worth noting, however, that SAWSDL does
not preclude include this type of annotations as illustrated in the usage guide gener-
ated by the SAWSDL Working Group [1].

Besides discarding preconditions and effects, in SAWSDL the construct Cate-
gory has been replaced by the more general modelReference extension attribute,
which in SAWSDL can be used to annotate XML Schema complex type deﬁnitions,
simple type deﬁnitions, element declarations, and attribute declarations, as well as
WSDL interfaces, operations, and faults. Additionally, schemaMapping has been
decomposed into two different extension attributes, namely liftingSchemaMapping
and loweringSchemaMapping, so as to speciﬁcally identify the type of transforma-
tion.

Listing 11.5 gives an excerpt of a WSDL service description extended with the
SAWSDL attributes which reference the mapping used to lower the instance of the
OrderRequest element, and to its ontological annotation.

11.3.2 Semantics-Based Discovery of Web Services

The Universal Description, Discovery and Integration (UDDI) speciﬁcation and
the Universal Business Registry (UBR) are the main industrial efforts towards the
automation of Web service discovery. The METEOR-S Web Services Discovery

268

11 OWL-S and Other Approaches

Infrastructure (MWSDI) [28] attempts to enhance existing Web services discov-
ery infrastructure by using semantics. MWSDI is a scalable infrastructure for the
semantics-based publication and discovery of Web services.

MWSDI aims to provide uniﬁed access to a large number of third party registries.
Thus, in order to provide a scalable and ﬂexible infrastructure, it has been imple-
mented using Peer-to-Peer (P2P) computing techniques. It is based on a four-layered
architecture which includes a Data layer, a Communications layer, an Operator Ser-
vices layer, and a Semantic Speciﬁcation layer. The Data layer consists of the Web
services registries and is based on UDDI. The Communications layer is the P2P
infrastructure which is based on JXTA. The Operator Services layer provides the
semantic discovery and publication of Web services. Finally, the Semantic Speciﬁ-
cation layer enhances the framework with semantics.

MWSDI uses semantics for two purposes. Firstly, it uses the so-called Registries
Ontology which stores registries information, maintains relationships between do-
mains within MWSDI and associates registries to them. This ontology stores map-
pings between registries and domains so that ﬁnding Web services for a speciﬁc
domain can be directed to the appropriate registries. Additionally, the Registries
Ontology captures relationships between registries so that searches can be made
more selective on the basis of these relationships.

Secondly, MWSDI envisions including domain speciﬁc ontologies for registries,
so that Web services can be annotated by mapping inputs and outputs to existing
domain ontologies. The purpose of deﬁning these mappings is to enable seman-
tic discovery by allowing users to express their requirements as Service Templates
which are expressed using concepts from the same ontology.

The semantic publication of services in MWSDI registries uses UDDI tModels
for registering the domain ontologies and CategoryBags for categorizing WSDL
entities according to one or more tModels. MWSDI provides both a manual and a
semi-automatic mechanism for deﬁning the mappings between WSDL elements and
the concepts in the domain ontologies [28].

11.3.3 Composition of Web Services

Semantic Composition of Web services in METEOR-S is supported by the so-called
METEOR-S Web Service Composition Framework (MWSCF) [23]. In a nutshell,
the composition framework makes use of Semantic Process Templates which con-
ceive processes as a set of semantically represented activities. Based on such tem-
plates, executable processes can be generated by binding the semantically deﬁned
activities to concrete Web services that conform to the activities’ speciﬁcation. As
presented in Fig. 11.7 due to [23], the MWSCF is composed of four components:
the process builder, the discovery infrastructure, XML repositories and the process
execution engine. The process builder includes a graphical user interface for deﬁn-
ing Semantic Process Templates, and a process generator. The process generator

11.3 METEOR-S

269

Fig. 11.7 METEOR-S composition framework

retrieves ontologies, activity interfaces and process templates from the XML repos-
itories, and uses MWSDI for discovering suitable Web services, in order to trans-
form the templates into executable processes. The executable process deﬁnitions can
then be handed to the process execution engine for the actual execution of the Web
service composition.

In MWSCF, Semantic Process Templates are basically a set of Activities con-
nected by means of BPEL control ﬂow constructs. Activities can be deﬁned with
a varying degree of ﬂexibility by using a speciﬁc Web service implementation, a
Web service interface or a Semantic activity template. Speciﬁc Web services imple-
mentations can be speciﬁed for static compositions. Web services interfaces can be
applied to gain some ﬂexibility allowing diverse implementations of the same in-
terface to be interchangeable executed. Finally, Semantic activity templates provide
a greater degree of ﬂexibility by deﬁning activities semantically in terms of their
inputs, outputs and functional semantics, e.g., preconditions and effects.

The creation of an executable process is a multi-step, semi-automated process
performed at design time, where the user is assisted in reﬁning the template with
concrete Web services and dataﬂow information (see Fig. 11.8 due to [23]). In order
to do so, Web services that implement the speciﬁed service interfaces are retrieved
from the XML Repository, and MWSDI is used for discovering suitable services
when semantic activity templates have been speciﬁed. After all the activities have
been replaced by concrete Web service instances, the user can map service outputs to
other service inputs in order to deﬁne the process dataﬂow. Based on the speciﬁed
dataﬂow, the process generator creates the executable representation, which is a
BPEL4WS process that can be executed in any BPEL execution engine.

11.3.4 METEOR-S Summary

Table 11.2 illustrates METEOR-S’ compliance to the criteria introduced
in Sect. 11.1.

270

11 OWL-S and Other Approaches

Fig. 11.8 Composition steps supported by MWSCF

Table 11.2 METEOR-S summary

Compliance Criteria

Comments

√

√

√

√

√

Web compliance

Ontology-based

Strict decoupling

Supports URI, namespaces and XML

Based on DAML and RDF-S

Ontologies and services are speciﬁed indepen-
dently

Centrality of mediation

Supported but not as a central concept

Ontological role separation

Doesn’t have the notion of user desires

Description vs. implementation Strongly coupled with existing Web service stan-

dards

Execution semantics

Doesn’t have the notion of execution semantics

Services vs. Web Services

Designed as a means to describe Web services

11.4 IRS-III

The Internet Reasoning Service (IRS) project7 [4] carried out at the Knowledge
Media Institute at the Open University has the overall aim of supporting the auto-
mated or semi-automated construction of semantically enhanced systems over the

7http://kmi.open.ac.uk/projects/irs.

11.4

IRS-III

Fig. 11.9 IRS-III
architecture

271

Internet. The latest version of IRS, called IRS-III [4], has incorporated and extended
the WSMO ontology so that the implemented infrastructure allows the description,
publication and execution of Semantic Web Services.

IRS-III is based on a distributed architecture composed of the IRS-III server, the
publishing platforms, and various clients, as shown in Fig. 11.9. The server embeds
an OCML [15] interpreter, which includes all the reasoning machinery for manip-
ulating ontologies deﬁnitions and invoking Web services in order to satisfy client
requests expressed as goals. In order to support the invocation of Semantic Web
Services, the reasoning engine is complemented by the Orchestration Interpreter,
the Choreography Interpreter, the Mediation Handler and the Invoker.

The server provides access to client applications for creating and editing WSMO
descriptions of goals, Web services and mediators and supports the achievement of
stored goals by invoking previously deployed Web services. Clients communicate
with the server by means of a stack of Java libraries, encapsulated in the yellow box
in Fig. 11.9. The libraries provide programmatic access to the server functionality
and perform the appropriate transformations between WSMO and OCML code. Fur-
thermore, an implementation of the current version of the Semantic Execution Envi-
ronment API is also available, so that compatible applications, such as the WSMO

272

11 OWL-S and Other Approaches

Studio or the Web Service Modeling Toolkit (WSMT), can make use of IRS in an
homogeneous way.

Through the publishing platforms service providers can attach semantic descrip-
tions to their Web services; moreover, handlers allow for the invocation of services
expressed in various languages and formats—currently, IRS supports WSDL, Lisp
code, Java code, and Web applications. When a Web service is published in IRS-III,
the information about the publishing platform is also associated with the Web ser-
vice description in order for the service to be invoked. The Java and WSDL pub-
lishing platforms are delivered as Java Web applications, whereas both the Lisp and
HTTP publishers have been developed in Lisp.

IRS-III has its own internal representation of the WSMO meta-model in OCML
and introduces some speciﬁc modiﬁcations and extensions which we review next.
A ﬁrst aspect that differs from WSMO is the fact that in IRS-III goals and Web ser-
vices have an explicit declaration of input and output roles which includes the name
and the semantic type. This approach contrasts with WSMO where this information
is deﬁned in the State Signature as part of the Choreography speciﬁcation.

A second notable feature, closely related to the previous one, comes from the
fact that Web services can inherit the input and output roles of goals. As a conse-
quence, roles declaration in Web services are not mandatory although they can be
used to extend and reﬁne existing deﬁnitions of roles. This feature is enabled as in-
puts and output roles are deﬁned as part of goals and Web services, as opposed to the
approach prescribed in WSMO, and supports further reuse of existing deﬁnitions.

In addition to the speciﬁc extensions to WSMO included in IRS-III, further dis-
tinguishing characteristics arise from the underlying modeling support they use.
WSMO is deﬁned using the Meta-Object Facility (MOF) [18] which speciﬁes a
metadata architecture based on fours layers. In WSML, the meta-model is sepa-
rate from the deﬁnitions made in the language, which means that it is a separate
meta-theory. Domain and application speciﬁc deﬁnitions span the information and
model layers where Web service, ontology, goal and mediator are basically lan-
guage constructs. Consequently, when modeling any speciﬁc domain in WSML,
there is no possibility to treat a Web service, ontology, goal or mediator as concepts
which could be subsumed or instantiated. This supports the execution of Web ser-
vices, since existing WSML-based software has embedded knowledge in order to
deal with these concepts. However, this separation of layers also comes with some
important drawbacks.

A ﬁrst inconvenience is, as pointed out in [25], the fact that it is important to dis-
tinguish between prototypical goals, which represent the speciﬁc static deﬁnitions,
and the actual instantiations of these goals containing invocation data. The authors
refer to these as goal templates and goal instances, respectively; the introduction of
goal templates proposed in [25] is a way to partially overcome part the limitations
introduced by the MOF-based deﬁnition of WSMO.

Secondly, since at the model-level a goal is merely a construct, one cannot ben-
eﬁt from subsumption reasoning. Supporting the creation of goal hierarchies would
promote and support reusing deﬁnitions. Goal achievement could be enhanced by
supporting the dynamic selection of reﬁned Goals taking non-functional properties

11.4

IRS-III

273

into account, for example. Similarly, facing situations where a speciﬁc goal cannot
be achieved, systems could decide to meet at least some of the client requirements
by achieving a more generic goal. So far, this is supported in WSMO by means of
ggMediators, but using these requires additional ad-hoc reasoning facilities where
pre-existing reasoning machinery could be applied (in this case, most prominently
subsumption). In fact, ggMediators do not specify whether the relationship between
goals is one of equivalence or reﬁnement.

In IRS-III, these inconveniences are overcome in OCML by deﬁning both the
meta-model (WSMO) and the user models in the same language, i.e., both the
WSMO meta-concept of goal and speciﬁc user goals—the previously mentioned
templates—are both OCML classes. In this way, there is support for the instantia-
tion of goals, as well as for the deﬁnition of relationships between goals.

11.4.1 Discovery, Selection and Mediation

In IRS, discovery is based on the existing ontological connection between goals and
services expressed via wgMediators. Such connections can be dynamically com-
puted when a new goal is submitted, but the assumption is that IRS enacts a sta-
ble broker between pre-existing goals and external deployed Web services. Having
found a mediator connecting a goal to some candidate services, the IRS selects the
most suitable on the basis of the preconditions and assumptions deﬁned in their
capability.

In order to support this model of discovery and selection, IRS has some exten-
sions and differences in interpretation of the WSMO model from that applied by
WSMX. Firstly, goals are implicitly assumed to be atomic and explicitly parame-
terized in inputs, which are therefore all required before execution. For this reason,
there is no need for a behavioral part to a goal’s choreography in the IRS. Secondly,
a WSMO web service is viewed as the application of an external deployed service
to a particular atomic task. While this requires only the communication of inputs
from the user, and return of an output, IRS as a broker may be required to carry
out several interactions with the deployed service to reach this output. The proto-
type of this interaction is stored in the choreography of the service and is called a
‘client choreography’. This is different from the model of goal choreographies and
service choreographies which need dynamic process mediation in WSMX. Process
mediation may be used to form client choreographies when service descriptions are
added to IRS to make deployed services available for new tasks but, like dynamic
discovery, this is outside the scope of the current tool.

Data mediation in IRS is encoded in the wgMediator, which links a goal and
Web service and may take one of three forms, each allowing the inputs of the goal
to be turned into the inputs required by the Web service, and the outputs provided
by the Web service to be turned into the output expected by the goal. Firstly, the
IRS model of ooMediator is extended to allow OCML rules mapping between in-
stances of concepts within the ontologies speciﬁed. In this way, wgMediators can

274

11 OWL-S and Other Approaches

be linked to ooMediators including a declarative speciﬁcation of the data mediation.
This is similar to the approach of the abstract mapping language engine described
for WSMX, but explicitly attached to the mediator description. The other means to
provide data mediation in IRS are via the service abstraction and the ‘usesMedi-
ationService’ attribute of WSMO’s wgMediator. This can be used either to attach
a service which can convert between goal and service inputs, or service and goal
outputs, as described above, or to attach a goal which describes the requirements on
such a mediation service. In the latter case, discovery and selection can be applied
recursively so that the link between a goal and candidate service may depend on the
existence of such a mediation service.

The capability-driven selection mechanism provided by IRS-III has recently been
extended to encompass trust-based requirements and guarantees [7]. A Web Ser-
vices Trust Ontology (WSTO) has been built with which WSMO-based descriptions
can be extended and a classiﬁcation-based algorithm is used to discount and rank
candidate services according to the ‘trustworthiness’ of their guarantees on certain
non-functional aspects, such as quality of service.

11.4.2 Communication

The distributed architecture of IRS is composed of three main blocks: the server, the
stack of libraries, and the publishing platforms. Interactions between components
belonging to the same block take place in the same execution environment, and are
based on direct invocation.8 As a consequence, supporting this does not require any
speciﬁc communication infrastructure.

Describing the communication mechanisms implemented in the IRS concerns
three interactions. The ﬁrst one corresponds to the communication between clients
and IRS as supported by the libraries stack. This stack of libraries provides access
to the main IRS functionality such as the manipulation of knowledge models and
the invocation of goals. The communication between Java libraries and IRS is cen-
tralized in the IRS-III API, which acts as the unique access point to the IRS server
as a set of methods that manipulate OCML deﬁnitions (see Fig. 11.9). Additionally,
it includes a server that enables runtime monitoring of the IRS server tracking all
internal processes. Communication between the IRS-III API and the server, both
inbound and outbound, is based on SOAP. Each client request/reply interaction is
supported by SOAP and a set of pre-deﬁned XML messages formats. Similarly,
every tracked activity generates events expressed in terms of an Events Ontology;
these events are then serialized and forwarded to the monitoring server via SOAP.

The second communication affects the interaction between the IRS server and
the publishing platforms. Four different types of remote services—Lisp code, Java
code, WSDL Web services and Web applications—can be invoked via HTTP GET

8Note that there is no interaction between publishers.

11.4

IRS-III

275

requests. The ﬁrst three types are handled by the appropriate component of the pub-
lishing platform, whereas Web applications are directly invoked by the IRS server
as it has built-in HTTP support. The remaining publishing platforms—Java, WSDL
and Lisp—are external components that communicate with the server via SOAP.
An important aspect of this communication concerns the transition between the se-
mantic world and the syntactic world, usually referred to as lifting and lowering in
the Semantic Web Services community. This functionality is provided in IRS by the
Invoker. The current implementation of the IRS includes lifting and lowering ma-
chinery for dealing with XML-based results. The relevant information for perform-
ing the appropriate transformations is stored as a set of Lisp macros which identify
the data interchanged, the relevant Semantic Web Service and the corresponding
XML element by means of an XPath expression. At runtime the Invoker retrieves
information on how to lift or lower the data and applies it right after receiving the
results or right before sending the invocation data, respectively. This way, the data
sent to the publisher is always in its syntactic representation whereas internally the
IRS manipulates semantic data.

The ﬁnal communication takes place between the different publishing platforms
and the actual Semantic Web Service being invoked, and it is therefore platform spe-
ciﬁc. For instance, Lisp code is executed in the Lisp publishing platform, WSDL ser-
vices are invoked using the protocol speciﬁed, Web applications are invoked through
HTTP, and Java services are provided by a Java-based Web application deployed on
a Tomcat Web server so as to be invocable.

11.4.3 Choreography and Orchestration

As discussed in Sect. 11.4.1, choreography in the IRS model consists of the attach-
ment of client choreographies to Web services. The choreography engine is applied
to execute a client choreography when a Web service is selected in order to meet
a Goal. Whereas the separation of client and service choreographies, together with
dynamic mediation between them, in WSMX allows the parties and communica-
tion roles in these choreographies to be implicit, a client choreography implicitly
includes communications via the broker and a more sophisticated model of commu-
nication is required. The choreography model of IRS is detailed in [5].

The IRS offers two models for orchestrations attached to Web service descrip-
tions. In both cases, these models are executable and derive the required atomic
behavior from a complex interaction between some number of other artifacts.

In the simplest case, described in [4], control ﬂow primitives are used to link
together goals to form a complex behavior. ggMediators are used to form the data
ﬂow between these goals; when a ggMediators connects one goal to another, the
input will be taken from the source goal and communicated to whichever input of
the target goal matches the mediator’s output. This may involve data mediation as
described for wgMediators above. One consequence of this model is that a given
goal may only be instantiated once per orchestration or the data ﬂow is ambiguous.

276

Table 11.3 Overall
comparison of the SWS
frameworks

11 OWL-S and Other Approaches

WSMO OWL-S METEOR-S

Web compliance

Ontology-based

Strict decoupling

Centrality of mediation

Ontological role separation

Description vs. implementation

Execution semantics

Services vs. Web services

√

√

√

√

√

√

√

√

√

√

√

√

√

√

√

√

√

√

It is also not permitted to directly specify another Web service to be applied during
the orchestration.

Both of the stated deﬁciencies of the simple orchestration model are addressed
in the Cashew orchestration model [17]. Here both goals and Web services can be
speciﬁed in prototypical ‘performances’ which are the units of behavior composed
in a hierarchical control ﬂow decomposition. The data ﬂow is unambiguously spec-
iﬁed by a new type of mediator between performances, named a ppMediator. As
described for wg- and ggMediators, the usual attributes may be used to specify data
mediation. The second advantage of the Cashew model is the ability to represent this
model in UML Activity Diagrams, and work has been carried out on composition
in this model with execution via the Cashew orchestration implementation [17].

11.5 Summary

In this chapter, we introduced additional frameworks which aim to fulﬁll the promise
of the Semantic Web Services vision. The ﬁrst part was devoted to OWL-S where
we described its basic building blocks (i.e., service proﬁle, service model and ser-
vice grounding) used to semantically describe and ground a Web service. We also
gave an overview of the OWL-S tool support. The second part of the chapter de-
scribed METEOR-S as a pragmatic SWS approach founded on heavily used and
standardized speciﬁcations such as WSDL. As opposed to the other SWS frame-
works presented in this book, the METEOR-S promotes a bottom-up approach to
semantically enabling Web services technology, which relies on SAWSDL. Again,
we paid some attention to the tools used to support semantic annotation, discov-
ery and composition tasks in the METEOR-S environment. Towards the end of the
chapter, we presented IRS-III as an environment which supports and further extends
WSMO with a strong emphasis on the automated and semi-automated development
of semantically enhanced systems.

The SWS frameworks have been assessed with regards to the criteria introduced
at the beginning of the chapter. Table 11.3 summarizes the results of this assessment.

11.6 Exercises

11.6 Exercises

277

Exercise 1 Given the scenario description of the exercise in Chap. 9, try to for-
malize a set of ontologies and Web service descriptions following OWL-S. Discuss
similarities and differences to a WSMO-based solution.

References

1. Akkiraju, R., Sapkota, B.: Semantic annotations for WSDL and XML schema—usage guide.

Working Group Note (2007). http://www.w3.org/TR/sawsdl-guide/

2. Akkiraju, R., Farrell, J., Miller, J., Nagarajan, M., Schmidt, M.-T., Sheth, A., Verma, K.:
Web Service Semantics—WSDL-S. W3C Member Submission (2005). http://www.w3.org/
Submission/WSDL-S/

3. Battle, S., Bernstein, A., Boley, H., Grosof, B., Gruninger, M., Hull, R., Kifer, M., Martin, D.,
McIlraith, S., McGuinness, D., Su, J., Tabet, S.: Semantic Web services framework (swsf)
overview. W3C Member Submission 9 September 2005. http://www.w3.org/Submission/
SWSF

4. Cabral, L., Domingue, J., Galizia, S., Gugliotta, A., Norton, B., Tanasescu, V., Pedrinaci, C.:
IRS-III: a broker for Semantic Web services based applications. In: Proceedings of the 5th
International Semantic Web Conference (ISWC) (2006)

5. Domingue, J., Galizia, S., Cabral, L.: Choreography in IRS III: coping with heteroge-
neous interaction patterns in Web services. In: 4th International Semantic Web Conference
(ISWC2005), 6–10 November 2005 (2005)

6. Farrell, J., Lausen, H.: Semantic annotations for WSDL and XML schema. W3C Candidate

Recommendation 26 January 2007. http://www.w3.org/TR/sawsdl/

7. Galizia, S., Gugliotta, A., Domingue, J.: A trust-based methodology for Web service selection.

In: Proceedings of 1st IEEE Conference on Semantic Computing (2007)

8. Grüninger, M., Menzel, C.: The process speciﬁcation language (psl) theory and applications.

The AI Magazine 24(3), 63–74 (2003)

9. Haarslev, V., Möller, R.: Racer: a core inference engine for the Semantic Web. In: Proceedings
of 2nd International Workshop on Evaluation of Ontology-Based Tools (EON 2003), pp. 27–
36 (2003)

10. Klusch, M., Renner, K.-U.: Fast dynamic re-planning of composite OWL-S services. In: Pro-
ceedings of 2006 IEEE/WIC/ACM International Conference on Web Intelligence and Intelli-
gent Agent Technology, pp. 134–137. IEEE Computer Society, Los Alamitos (2006)

11. Klusch, M., Fries, B., Sycara, K.: Automated Semantic Web service discovery with OWLS-
MX. In: Proceedings of 5th International Conference on Autonomous Agents and Multi-Agent
Systems (AAMAS). ACM Press, New York (2006)

12. Martin, D., Burstein, M., Hobbs, J., Lassila, O., McDermott, D., McIlraith, S., Narayanan,
S., Paolucci, M., Parsia, B., Payne, T., Sirin, E., Srinivasan, N., Sycara, K.: OWL-S: Semantic
markup for Web services. W3C, Member Submission (2004). http://www.w3.org/Submission/
OWL-S

13. McGuinness, D.L., van Harmelen, F.: OWL Web Ontology Language. W3C, Recommenda-

tion (2004). http://www.w3.org/TR/owl-features

14. Motik, B., Sattler, U., Studer, R.: Query answering for OWL-DL with rules. In: Proceedings
of 3rd International Semantic Web Conference (IWSC 2004). LNCS, vol. 3298, pp. 549–563
(2004)

15. Motta, E.: Reusable Components for Knowledge Modelling. Case Studies in Parametric De-
sign Problem Solving. Frontiers in Artiﬁcial Intelligence and Applications, vol. 53. IOS Press,
Amsterdam (1999)

278

11 OWL-S and Other Approaches

16. Norton, B.: Experiences with OWL-S, directions for service composition. In: Proceedings of

OWL: Experiences and Directions Workshop (OWLED-2005) (2005)

17. Norton, B., Pedrinaci, C., Henocque, L., Kleiner, M.: 3-level behaviour models for Seman-
tic Web services. International Transactions on Systems Science and Applications (2007, to
appear)

18. Object Management Group Inc. (OMG): Meta Object Facility (MOF) Speciﬁcation V1.4.

(2002). http://www.omg.org/technology/documents/formal/mof.htm

19. Paolucci, M., Ankolekar, A., Srinivasan, N., Sycara, K.: The DAML-S virtual machine. In:
Proceedings of 2nd International Semantic Web Conference (ISWC 2003). LNCS, vol. 2870,
pp. 290–305. Springer, Berlin (2003)

20. Paolucci, M., Srinivasan, N., Sycara, K.: Expressing WSMO mediators in OWL-S. In: Pro-
ceedings of Semantic Web Services: Preparing to Meet the World of Business Applications
(2004)

21. Patil, A.A., Oundhakar, S.A., Sheth, A.P., Verma, K.: METEOR-S Web service annotation
framework. In: WWW’04: Proceedings of the 13th International Conference on World Wide
Web, pp. 553–562. ACM Press, New York (2004). doi:10.1145/988672.988747

22. Sirin, E., Parsia, B., Grau, B.C., Kalyanpur, A., Katz, Y.: Pellet: a practical OWL-DL reasoner.

Journal of Web Semantics 5(2), 51–53 (2004)

23. Sivashanmugam, K., Miller, J.A., Sheth, A.P., Verma, K.: Framework for Semantic Web pro-

cess composition. International Journal of Electronic Commerce 9(2), 71–106 (2005)

24. Srinivasan, N., Paolucci, M., Sycara, K.: Adding OWL-S to UDDI: implementation and
throughput. In: Proceedings of 1st International Conference on Semantic Web Services and
Web Process Composition (SWSWPC 2004) (2004)

25. Stollberg, M., Norton, B.: A reﬁned goal model for Semantic Web services. In: The Second
International Conference on Internet and Web Applications and Services (ICIW 2007) (2007).
ISBN: 0-7695-2844-9

26. Szomszor, M., Payne, T., Moreau, L.: Automated syntactic mediation for web services in-
tegration. In: Proceedings of IEEE International Conference on Web Services (ICWS 2006)
(2006)

27. Tsarkov, D., Horrocks, I.: FaCT++ description logic reasoner: system description. In: Pro-
ceedings of 3rd International Joint Conference on Automated Reasoning. LNCS, vol. 4130,
pp. 292–297. Springer, Berlin (2006)

28. Verma, K., Sivashanmugam, K., Sheth, A., Patil, A., Oundhakar, S., Miller, J.: METEOR-S
WSDI: a scalable P2P infrastructure of registries for semantic publication and discovery of
web services. International Journal of Information Technology and Management 6(1), 17–39
(2005). doi:10.1007/s10799-004-7773-4

29. Wu, D., Parsia, B., Sirin, E., Hendler, J., Nau, D.: Automating DAML-S web services compo-
sition using SHOP2. In: Proceedings of 2nd International Semantic Web Conference (IWSC
2003). LNCS, vol. 2870. Springer, Berlin (2003)

Chapter 12
Lightweight Semantic Web Service Descriptions

Abstract The Web standardization consortium W3C has developed a lightweight
bottom-up speciﬁcation, Semantic Annotation for WSDL (SAWSDL), for adding
semantic annotations to WSDL service descriptions. In this chapter, we de-
scribe SAWSDL, and then we present WSMO-Lite and MicroWSMO, two related
lightweight approaches to Semantic Web Service description, evolved from the Web
Service Modeling Ontology (WSMO) framework. WSMO-Lite deﬁnes an ontology
for service semantics, used directly in SAWSDL to annotate WSDL-based services.
MicroWSMO and its basis, hRESTS, are microformats that supplement WSDL and
SAWSDL for unstructured HTML descriptions of services, providing WSMO-Lite
support for the growing numbers of RESTful services.

12.1 Motivation

As the ﬁrst step towards standardizing semantic descriptions for Web services, the
Web standardization consortium W3C has developed a lightweight bottom-up spec-
iﬁcation for annotating WSDL service descriptions. The speciﬁcation is called Se-
mantic Annotations for WSDL and XML Schema (SAWSDL, [3, 6]).

Technologies such as WSMO (cf. Chap. 7) and OWL-S (cf. Chap. 11) embody
the so-called top-down approach to semantic Web service modeling: a service en-
gineer describes the semantics of the service independently of the actual realization
in the service implementation; then the semantics is grounded in an underlying de-
scription such as WSDL. This approach separates the semantics from the underlying
WSDL, on the principle that the semantics should not be inﬂuenced by implemen-
tation details.

In contrast, SAWSDL embodies a bottom-up modeling approach where the
WSDL layer that describes the service on the implementation level forms the basis
for adding semantics. With a bottom-up approach, semantics are added to WSDL
descriptions in a modular fashion, as needed in a concrete deployment. SAWSDL
by itself, however, does not specify any actual types of semantics; it only gives
us hooks for attaching semantics to WSDL descriptions. SAWSDL is the ground
stone on which semantic Web services frameworks should be built, and a catalyst
for building them. We further describe SAWSDL in Sect. 12.2.1.

The standardization of SAWSDL led to the development of WSMO-Lite [4], an
emerging technology that realizes the WSMO Semantic Web Services approach in

D. Fensel et al., Semantic Web Services,
DOI 10.1007/978-3-642-19193-0_12, © Springer-Verlag Berlin Heidelberg 2011

279

280

12 Lightweight Semantic Web Service Descriptions

Fig. 12.1 WSMO-Lite and
MicroWSMO layer cake

SAWSDL and RDF. WSMO-Lite identiﬁes four types of semantics and deﬁnes a
lightweight RDF Schema ontology for expressing them. Built on a simpliﬁed ser-
vice model, WSMO-Lite applies directly to WSDL services, described in Chap. 4.
We present the service semantics deﬁned by WSMO-Lite in Sect. 12.2.2, and in
Sect. 12.2.3, we show the speciﬁcs of how WSMO-Lite applies to WSDL descrip-
tions.

The WSMO-Lite service model also maps naturally to RESTful services, de-
scribed in Chap. 5. However, at the time of writing, there is no widely accepted
standard for machine-readable descriptions of RESTful services, which are instead
simply documented in HTML Web pages. Faced with HTML pages, we employ
two microformats (an “adaptation of semantic XHTML that makes it easier to pub-
lish, index, and extract semi-structured information” [2]) to make the key pieces
of the human-oriented service documentation machine-readable (hRESTS), and to
add semantic annotations (MicroWSMO). Both microformats, deﬁned in [5], are
described in Sect. 12.2.4.

12.2 Technical Solution

Figure 12.1 shows the relative positioning of WSMO-Lite, WSDL with SAWSDL,
and hRESTS with MicroWSMO. WSDL is the standard description language for
Web services; SAWSDL extends it with annotations that can point to semantics,
such as WSMO-Lite. hRESTS is analogous to WSDL—it describes the basic struc-
ture of RESTful services. MicroWSMO is then a direct realization of SAWSDL
annotations over hRESTS. Both SAWSDL and MicroWSMO are annotation mech-
anisms enabling pointers to semantics; WSMO-Lite speciﬁes a simple vocabulary
for four types of semantics that ﬁt in SAWSDL/MicroWSMO annotations.

Below, we ﬁrst describe SAWSDL, the simple speciﬁcation that is the corner-
stone of lightweight semantic Web services frameworks. Then we proceed to detail
WSMO-Lite, with its simple service model and four types of service semantics. Af-
terwards, we show exactly how WSMO-Lite semantics are applied in WSDL and
SAWSDL. Finally, we extend the reach of WSMO-Lite also to RESTful services,
using the microformats hRESTS and MicroWSMO.

12.2 Technical Solution

12.2.1 SAWSDL

281

SAWSDL is a set of extensions for WSDL,1 the standard description format for Web
services. To brieﬂy recap from Chap. 4, WSDL uses XML as a common ﬂexible data
exchange format, and applies XML Schema for data typing. WSDL describes a Web
service in three levels:
• Reusable abstract interface deﬁnes a set of operations, each representing a simple

exchange of messages described with XML Schema element declarations.

• Binding describes the on-the-wire message serialization, following the structure
of an interface and ﬁlling in the necessary networking details (for instance, for
SOAP or HTTP).

• Service represents a single physical Web service which implements a single in-

terface; the Web service can be accessible at multiple network endpoints.

The purpose of WSDL is to describe the Web service on a syntactic level: WSDL
speciﬁes what the messages look like rather than what the messages or operations
mean. SAWSDL deﬁnes an extension layer over WSDL that allows the semantics
to be speciﬁed on the various WSDL components. SAWSDL deﬁnes extension at-
tributes that can be applied to elements both in WSDL and in XML Schema in order
to annotate WSDL interfaces, operations and their input and output messages.

The SAWSDL extensions are of two forms: model references point to semantic
concepts, and schema mappings specify data transformations between the XML data
structure of messages and the associated semantic model.

12.2.1.1 Model Reference

A model reference is an extension attribute, sawsdl:modelReference, that
can be applied to any WSDL or XML Schema element, in order to point to one or
more semantic concepts. The value is a set of URIs, each one identifying some piece
of semantics.

Model reference has the very generic purpose of referring to semantic concepts.
As such, it serves as a hook where semantics can be attached. As illustrated in the
examples presented later in this chapter, model reference can be used to describe the
meaning of data or to specify the function of a Web service operation.

12.2.1.2 Schema Mappings

Schema mappings are represented by two attributes, sawsdl:liftingSchema-
Mapping and sawsdl:loweringSchemaMapping. Lifting mappings trans-
form XML data from a Web service message into a semantic model (for instance,

1Web Services Description Language, http://www.w3.org/TR/wsdl20/.

282

12 Lightweight Semantic Web Service Descriptions

Fig. 12.2 RDF data lifting
and lowering for WS
communication

Fig. 12.3 RDF data lifting
and lowering for data
mediation

into RDF data that follows some speciﬁc ontology), and lowering mappings trans-
form data from a semantic model into an XML message.

Lifting and lowering transformations are required for communication with the
Web service from a semantic client: the client software will lower some of its se-
mantic data into a request message and send it to the Web service, and when the
response message is received, it can be lifted for semantic processing. This is illus-
trated in Fig. 12.2.

Lifting and lowering annotations can also be used for XML data mediation
through a shared ontology, as shown in Fig. 12.3. The data in one XML format can
be lifted to data in the shared ontology and then lowered to another XML format,
using the lifting annotation from the schema for the ﬁrst format, and the lowering
annotation from the second schema.

12.2.1.3 Annotation Propagation

In an XML Schema, the content of an element is described by a type deﬁnition,
and the name of the element is added as an element declaration. SAWSDL model
reference and schema mapping annotations can be both on types and on elements;
in fact, the annotations of a type apply also to all elements of that type.

In particular, for a given pair of an element declaration and its type deﬁnition,
the model references from the type are merged with the model references of the el-
ement, and all of them apply to the element. Schema mappings, on the other hand,
are only propagated from the type if the element does not declare any schema map-
pings of its own. This allows a type to provide generic schema mappings, and the

12.2 Technical Solution

Table 12.1 SAWSDL syntax summary

Name

Description

283

modelReference
(XML attribute)

liftingSchemaMapping
(XML attribute)

loweringSchemaMapping
(XML attribute)

attrExtensions
(XML element)

a list of references to concepts in some semantic
models

a list of pointers to alternative data lifting
transformations

a list of pointers to alternative data lowering
transformations

used for attaching attribute extensions where
only element extensibility is allowed

element to specify more concrete mappings appropriate for the speciﬁc use of the
type. Table 12.1 provides a summary of the syntactical constructs of SAWSDL.

12.2.1.4 WSDL 1.1 Support

While SAWSDL is primarily built for WSDL 2.0, the older and more prevalent ver-
sion WSDL 1.1 is also supported. Essentially, both model references and schema
mappings apply in the same places in both versions of WSDL. However, the
XML Schema for WSDL 1.1 only allows element extensions on operations, so a
WSDL 1.1 document with the SAWSDL sawsdl:modelReference attribute
on an operation would not be valid. To overcome this obstacle, SAWSDL deﬁnes
an element called sawsdl:attrExtensions that is intended to carry exten-
sion attributes in places where only element extensibility is allowed. Instead of
putting the model reference directly on the wsdl11:operation element, it is
put on the sawsdl:attrExtensions element, which is then inserted into the
wsdl11:operation element.

WSDL is a well-known and accepted language for describing Web service in-
terfaces, and virtually all Web service enabled systems use it to advertise and use
Web services. SAWSDL is a non-intrusive, simple extension of WSDL that enables
semantic annotations in a way that does not invalidate any existing uses of WSDL.
This makes it perfectly suitable as the basis for an ontology for describing Semantic
Web Services, working towards automation in service-oriented systems.

12.2.2 WSMO-Lite Service Semantics

WSMO-Lite is a lightweight technology for semantic description of Web services.
It distinguishes between the following four types of service semantics:
• Information model deﬁnes the semantics of input, output and fault messages.
• Functional semantics deﬁnes service functionality, that is, what a service can

offer to its clients when it is invoked.

284

12 Lightweight Semantic Web Service Descriptions

Fig. 12.4 Web service
description model with
attached semantics

• Non-functional semantics deﬁnes any incidental details speciﬁc to the imple-
mentation or running environment of a service, such as its price, location or qual-
ity of service.

• Behavioral semantics speciﬁes the protocol (ordering of operations) that a client

needs to follow when consuming a service.

These semantics apply to service descriptions, as illustrated in Fig. 12.4: func-
tional and non-functional semantics belong to the Web service as a whole, behav-
ioral semantics belong to the operations, and the information model describes the
input and output messages. With SAWSDL, the Web service description can contain
pointers to the semantics as appropriate.

The service model shown in Fig. 12.4 is very similar to the model of WSDL, but
it also applies to RESTful Web services (as shown in Chap. 5). It can be seen as the
minimal service model: a Web service provides several operations, each of which
can have input and output messages, along with possible input and output faults.

Figure 12.5 lists the WSMO-Lite ontology. The ontology consists of 3 main
blocks: a service model that uniﬁes the views of WSDL-based and RESTful Web
services, SAWSDL annotation properties for attaching semantics, and ﬁnally, classes
for representing those semantics.

Note that instances of the service model are not expected to be authored di-
rectly; instead, the underlying technical descriptions (WSDL, hRESTS) are parsed
in terms of this ontology, with SAWSDL pointers to instances of the service seman-
tics classes in the third block.

The service model is rooted in the class wsl:Service. In contrast to WSDL, this ser-
vice model does not separate the service from its interface, as such separation does
not need to be kept to support SWS automation. A service is a collection of oper-
ations (class wsl:Operation). Operations may have input and output messages, plus
possible fault messages (all in the class wsl:Message). Input messages (and faults2)
are those that are sent by a client to a service, and output messages (and faults) are
those sent from the service to the client.

2Input faults are uncommon but possible in some WSDL message exchange patterns.

12.2 Technical Solution

wsl:hasOutputMessage a rdf:Property ;

rdfs:domain wsl:Operation ;
rdfs:range wsl:Message .

rdfs:domain wsl:Service ;
rdfs:range wsl:Operation .
wsl:Operation a rdfs:Class .
wsl:hasInputMessage a rdf:Property ;

# WSMO−Lite service model classes and properties
# this model is a simpliﬁed WSDL−based view of Web services
wsl:Service a rdfs:Class .
wsl:hasOperation a rdf:Property ;

(cid:2)
1
# namespace declarations (this line is a comment)
2 @preﬁx owl: <http://www.w3.org/2002/07/owl#> .
3 @preﬁx rdf: <http://www.w3.org/1999/02/22−rdf−syntax−ns#> .
4 @preﬁx rdfs: <http://www.w3.org/2000/01/rdf−schema#> .
5 @preﬁx sawsdl: <http://www.w3.org/ns/sawsdl#> .
6 @preﬁx wsl: <http://www.wsmo.org/ns/wsmo−lite#> .
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40

wsl:FunctionalClassiﬁcationRoot rdfs:subClassOf rdfs:Class .
wsl:NonFunctionalParameter a rdfs:Class .
wsl:Condition a rdfs:Class .
wsl:Effect a rdfs:Class .
(cid:4)

# SAWSDL properties (included here for completeness)
sawsdl:modelReference a rdf:Property .
sawsdl:liftingSchemaMapping a rdf:Property .
sawsdl:loweringSchemaMapping a rdf:Property .

wsl:hasInputFault a rdf:Property ;
rdfs:domain wsl:Operation ;
rdfs:range wsl:Message .

rdfs:domain wsl:Operation ;
rdfs:range wsl:Message .
wsl:Message a rdfs:Class .

# WSMO−Lite service semantics classes
wsl:Ontology a rdfs:Class ;

rdfs:domain wsl:Operation ;
rdfs:range wsl:Message .

wsl:hasOutputFault a rdf:Property ;

rdfs:subClassOf owl:Ontology .

285
(cid:3)

(cid:5)

Fig. 12.5 Service Ontology, Captured in Notation 3. (A brief intro to the Notation 3 RDF
syntax: comment lines start with “#”, URIs are denoted as namespace-qualiﬁed names “a”,
is short for rdf:type,
triples end with a period, and triples with the same subject can be
grouped, having the next property–object pair after a semicolon instead of a period. More at
http://www.w3.org/DesignIssues/Notation3.html)

To link the components of the service model with the concrete description of
the functional, non-functional, behavioral and information semantics, as illustrated
in Fig. 12.4, we adopt the SAWSDL properties sawsdl:modelReference, sawsdl:lifting-
SchemaMapping and sawsdl:loweringSchemaMapping, deﬁned by the SAWSDL RDF
mapping in [6].

A model reference can be used on any component in the service model to point
to the semantics of that component. In particular, a model reference on a service
can point to a description of the service’s functional and non-functional semantics;
a model reference on an operation points to the operation’s part of the behavioral
semantics description; and a model reference on a message points to the message’s
counterpart(s) in the service’s information model. The lifting and lowering schema

286

12 Lightweight Semantic Web Service Descriptions

mapping properties complement the model references on messages, to point to the
appropriate data transformations.

A single component can have multiple model reference values, which all apply
together; for example, a service can have a number of non-functional properties
together with a pointer to its functionality description, or a message can be annotated
with multiple ontology classes, indicating that the message carries instances of all
the classes.

In the remainder of this subsection, we describe how the four types of service
semantics are represented in the WSMO-Lite service ontology. In the example list-
ings, we use the following namespace preﬁxes:

(cid:2)

1 @preﬁx rdfs: <http://www.w3.org/2000/01/rdf−schema#> .
2 @preﬁx rdf: <http://www.w3.org/1999/02/22−rdf−syntax−ns#> .
3 @preﬁx wsl: <http://www.wsmo.org/ns/wsmo−lite#> .
4 @preﬁx ex: <http://example.org/onto#> .
5 @preﬁx xs: <http://www.w3.org/2001/XMLSchema#> .
6 @preﬁx wsml: <http://www.wsmo.org/wsml/wsml−syntax#> .

(cid:4)

(cid:3)

(cid:5)

Information semantics are represented using domain ontologies. An ontology
intended for information semantics may be marked as wsl:Ontology (as shown below
on line 2), so that authoring tools can focus annotation suggestions more easily. The
following listing is an example domain ontology for a video-on-demand service:

(cid:2)
# ontology example
<> a wsl:Ontology.

ex:Customer a rdfs:Class .
ex:hasService a rdf:Property ;
rdfs:domain ex:Customer ;
rdfs:range ex:Service .
ex:Service a rdfs:Class .
ex:hasConnection a rdf:Property ;

rdfs:domain ex:Customer ;
rdfs:range ex:NetworkConnection .
ex:NetworkConnection a rdfs:Class .
ex:providesBandwidth a rdf:Property ;
rdfs:domain ex:NetworkConnection ;
rdfs:range xs:integer .

ex:VideoOnDemandService rdfs:subClassOf ex:Service .
(cid:4)

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16

(cid:3)

(cid:5)

Functional semantics are represented with functionality classiﬁcations and/or

preconditions and effects.

Functionality classiﬁcations deﬁne the service’s functionality using some classi-
ﬁcation taxonomy (i.e., a hierarchy of categories, such as the ecl@ss taxonomy3),
and the class wsl:FunctionalClassiﬁcationRoot marks a class that is a root of a classi-
ﬁcation. The classiﬁcation also includes all the RDFS subclasses of the root class.
Functionality classiﬁcations are coarse-grained means for describing service func-
tionality, due to the cost of creating shared taxonomies. An example functionality
classiﬁcation for subscription services is listed below:

3eCl@ss Standardized Material and Service Classiﬁcation, http://eclass-online.com.

12.2 Technical Solution

(cid:2)
# classiﬁcation example
ex:SubscriptionService a wsl:FunctionalClassiﬁcationRoot .
ex:VideoSubscriptionService rdfs:subClassOf ex:SubscriptionService .
ex:NewsSubscriptionService rdfs:subClassOf ex:SubscriptionService .
(cid:4)

1
2
3
4

287

(cid:3)

(cid:5)

Preconditions and effects can be more ﬁne-grained. They are logical expressions:
the preconditions must hold in a state before the client can invoke the service, and
the effects hold in a state after the service invocation. The current set of Web stan-
dards does not include a language for logical expressions, therefore the WSMO-Lite
classes wsl:Condition (for preconditions) and wsl:Effect are simply placeholders. In our
examples, we use WSML to express the logical expressions (cf. Chap. 8); we ex-
pect that in the future, the W3C Rule Interchange Format4 will be a suitable logical
expression language for preconditions and effects.

Non-functional semantics are represented using some ontology, semantically
capturing non-functional properties such as the price, location or quality of service
(QoS). The class wsl:NonfunctionalParameter marks a concrete piece of non-functional
semantics, such as the example price speciﬁcation below:

(cid:2)
# non−functional property example
ex:PriceSpeciﬁcation rdfs:subClassOf wsl:NonFunctionalParameter .
ex:VideoOnDemandPrice a ex:PriceSpeciﬁcation ;

ex:pricePerChange "30"^^ex:euroAmount ;
ex:installationPrice "49"^^ex:euroAmount .

(cid:4)

1
2
3
4
5

(cid:3)

(cid:5)

Behavioral semantics are represented by annotating the service operations with
functional descriptions, i.e., with functionality classiﬁcations and/or preconditions
and effects. Below, we show the preconditions and effects for a subscription opera-
tion on a video-on-demand service:

(cid:2)
# precondition and effect examples
ex:VideoOnDemandSubscriptionPrecondition a wsl:Condition ;

rdf:value """

?customer[ex#hasConnection hasValue ?connection]

memberOf ex#Customer and

?connection[ex#providesBandwidth hasValue ?y]

memberOf ex#NetworkConnection and

?y > 1000

"""^^wsml:AxiomLiteral .

ex:VideoOnDemandSubscriptionEffect a wsl:Effect ;

rdf:value """

?customer[ex#hasService hasValue ?service]

memberOf ex#Customer and

?service memberOf VideoOnDemandSubscription

"""^^wsml:AxiomLiteral .

# deﬁnition of the axiom for WSML language
wsml:AxiomLiteral a rdfs:Datatype .
(cid:4)

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18

4http://www.w3.org/2005/rules/.

(cid:3)

(cid:5)

288

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29

(cid:2)
<wsdl:description>

<wsdl:types><xs:schema>

12 Lightweight Semantic Web Service Descriptions
(cid:3)

...
<xs:element name="NetworkConnection" type="NetworkConnectionType"
sawsdl:modelReference="http://example.org/onto#NetworkConnection"
sawsdl:loweringSchemaMapping="http://example.org/NetCn.xslt"/>

...

</xs:schema></wsdl:types>
...
<wsdl:interface name="NetworkSubscription"

sawsdl:modelReference="http://example.org/onto#VideoSubscriptionService" >

<wsdl:operation name="SubscribeVideoOnDemand"

sawsdl:modelReference="

http://example.org/onto#VideoOnDemandSubscriptionPrecondition
http://example.org/onto#VideoOnDemandSubscriptionEffect">

<wsdl:input element="NetworkConnection"/>
...

</wsdl:operation>
...

</wsdl:interface>
...
<wsdl:service name="ExampleCommLtd"
interface="NetworkSubscription"
sawsdl:modelReference="http://example.org/onto#VideoOnDemandPrice">

<wsdl:endpoint name="public"
binding="SOAPBinding"
address="http://example.org/comm.ltd/subscription" />

</wsdl:service>
</wsdl:description>
(cid:4)

(cid:5)

Fig. 12.6 Various WSDL components with WSMO-Lite annotations

12.2.3 WSMO-Lite in SAWSDL

WSMO-Lite is based on the simpliﬁed service model shown in Fig. 12.4. In this
section, we describe a set of recommendations on how to annotate actual WSDL
descriptions with the four kinds of semantics, and a mapping from the annotated
WSDL structure to the WSMO-Lite RDFS service model, which is then the input
to semantic automation.

The listing in Fig. 12.6 shows WSMO-Lite annotations on an example WSDL
document. WSDL distinguishes between a concrete service (line 22) and its abstract
(and reusable) interface (line 10) that deﬁnes the operations (line 12). This structure
is annotated using SAWSDL annotations with the examples of semantics shown in
the preceding section.

The following paragraphs describe how the various types of semantics are at-

tached to the WSDL structure:

Functional semantics can be attached as a model reference either on the WSDL
service construct, concretely for the given service, or on the WSDL interface con-
struct (line 11), in which case the functional semantics apply to any service that
implements the given interface.

Non-functional semantics, by deﬁnition speciﬁc to a given service, are attached

as model references directly to the WSDL service component (line 24).

Information semantics are expressed in two ways. First, pointers to the semantic
counterparts of the XML data are attached as model references on XML Schema el-

12.2 Technical Solution

289

ement declarations and type deﬁnitions that are used to describe the operation mes-
sages (line 5). Second, lifting and lowering transformations need to be attached to
the appropriate XML schema components: input messages (going into the service)
need lowering annotations (line 6) to map the semantic client data into the XML
messages, while output messages need lifting annotations so the semantic client can
interpret the response data.

Finally, behavioral semantics of a service are expressed by annotating the ser-
vice’s operations (within the WSDL interface component, lines 13–15) with func-
tional descriptions, so the client can then choose the appropriate operation to invoke
at a certain point in time during its interaction with the service.

The mapping of a WSDL document into the WSMO-Lite RDFS service model is
mostly straightforward: a WSDL <wsdl:service> element becomes an instance
of WSMO-Lite wsl:Service, the WSDL operations of the interface implemented by
the service are attached to the WSMO-Lite service as instances of wsl:Operation,
with input, output and fault messages as speciﬁed in the WSDL operation. Model
references from a WSDL service map directly to model references on the WSMO-
Lite service instance; and similarly for model references on the operations.

Since WSMO-Lite does not represent a separate service interface, we combine
the interface annotations with the service annotations-model references on an inter-
face and added them to the model references of the service that implements this in-
terface. And ﬁnally, any annotations (model references and lifting/lowering schema
mappings) from the appropriate XML Schema components are mapped to annota-
tions of the messages in our service model.

The listing in Fig. 12.7 shows a generated RDF form that captures the data in
Fig. 12.6, using the lightweight WSMO-Lite RDFS ontology. Note the service, its
operation and the operation’s request message and the appropriate SAWSDL prop-
erties; Fig. 12.6 does not contain any additional data, therefore it is not shown in
Fig. 12.7.

12.2.4 WSMO-Lite for RESTful Services

In the case of RESTful services and Web APIs, there is no widely accepted machine-
readable service description language. WSDL 2.0 and WADL5 are two proposals
for such a language. However, the vast majority of public RESTful services are de-
scribed in plain unstructured HTML documentation. In this section, we present two
microformats, hRESTS and MicroWSMO, that enhance the HTML service docu-
mentation with machine-oriented structure and semantic annotations.

Microformats take advantage of existing XHTML facilities such as the class
and rel attributes to mark up fragments of interest in a Web page, making the
fragments more easily available for machine processing. For example, a calendar
microformat marks up events with their start and end time and with the event title,

5https://wadl.dev.java.net/.

290

(cid:2)

12 Lightweight Semantic Web Service Descriptions
(cid:3)

gen:ExampleCommLtd a wsl:Service ;

rdfs:isDeﬁnedBy <http://example.org/svc.wsdl> ;
sawsdl:modelReference ex:VideoOnDemandPrice ;
sawsdl:modelReference ex:VideoSubscriptionService ;
wsl:hasOperation gen:SubscribeVideoOnDemand .

1 @preﬁx ex: <http://example.com/onto#>
2 @preﬁx gen: <http://example.com/svc.wsdl#>
3 @preﬁx rdf: <http://www.w3.org/1999/02/22−rdf−syntax−ns#> .
4 @preﬁx rdfs: <http://www.w3.org/2000/01/rdf−schema#> .
5 @preﬁx sawsdl: <http://www.w3.org/ns/sawsdl#> .
6 @preﬁx wsl: <http://www.wsmo.org/ns/wsmo−lite#> .
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21

sawsdl:modelReference ex:NetworkConnection ;
sawsdl:loweringSchemaMapping <http://example.org/NetCn.xslt> .

sawsdl:modelReference ex:VideoOnDemandSubscriptionPrecondition ;
sawsdl:modelReference ex:VideoOnDemandSubscriptionEffect ;
wsl:hasInputMessage gen:SubscribeVideoOnDemandRequest .

gen:SubscribeVideoOnDemandRequest a wsl:Message ;

gen:SubscribeVideoOnDemand a wsl:Operation ;

(cid:4)

(cid:5)

Fig. 12.7 RDF representation of the WSDL/SAWSDL data in Fig. 12.6, using the WSMO-Lite
RDFS ontology

and a calendaring application can then directly import data from what otherwise
looks like a normal Web page.6

As we have shown in Chap. 5, even though the interaction model of RESTful
services (following links in a hypermedia graph) differs from that of SOAP services
(messaging), the service model is actually the same: a service contains a number of
operations with input and output messages. The hRESTS microformat captures this
structure with HTML classes service, operation, input and output that
identify the crucial parts of a textual service description.

In RESTful services, a service is a group of related Web resources, each of which
provides a part of the overall service functionality. The interaction of a client with
a RESTful service is a series of interactions where the client sends a request to
a resource (using one of the HTTP methods GET, POST, PUT or DELETE), and
receives a response that may link to further useful resources. While at runtime the
client interacts with concrete resources, the service description may present a single
operation that acts on many resources (e.g., getHotelDetails() which can be invoked
on any hotel details resource). An operation description in hRESTS can therefore
specify an address as an URI template whose parameters are part of the input data,
and the HTTP method that implements the operation. To capture this information,
hRESTS deﬁnes HTML classes address and method.

The deﬁnitions of the hRESTS HTML classes are summarized below, with point-
ers into the listing in Fig. 12.8, which shows an example hRESTS and MicroWSMO
service description:

6Further details on how microformats work can be found at http://microformats.org.

12.2 Technical Solution

(cid:2)
<div class="service" id="svc">

<h1><span class="label">ACME Hotels</span> service API</h1>

<p>This service is a

<a rel="model" href="http://example.com/ecommerce/hotelReservation">

hotel reservation</a> service.

</p>

<div class="operation" id="op1">

<h2>Operation <code class="label">getHotelDetails</code></h2>
<p> Invoked using the <span class="method">GET</span>

at <code class="address">http://example.com/h/{id}</code><br/>
<span class="input">

<strong>Parameters:</strong>
<a rel="model" href="http://example.com/data/onto.owl#Hotel">
<code>id</code></a> − the identiﬁer of the particular hotel
(<a rel="lowering" href="http://example.com/data/hotel.xsparql">lowering</a>)

</span><br/>
<span class="output">

<strong>Output value:</strong> hotel details in an
<code>ex:hotelInformation</code> document

</span>

</p>

</div></div>
(cid:4)

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22

Fig. 12.8 Example hRESTS and MicroWSMO service description

291
(cid:3)

(cid:5)

The service class on block markup (e.g., <body>, <div>), as shown in the
example listing on line 1, indicates that the element describes a service API. A ser-
vice contains one or more operations and may have a label (see below).

The operation class, also used on block markup (e.g., <div>), as shown in
the listing on line 7, indicates that the element contains a description of a single Web
service operation. An operation description speciﬁes the address and the method
used by the operation, and it may also contain description of the input and output of
the operation, and ﬁnally a label.

The address class is used on textual markup (e.g., <code>, shown on line 10)
or on a hyperlink (<a href>) and speciﬁes the URI of the operation, or the URI
template in case any inputs are URI parameters.

The method class on textual markup (e.g., <span>, shown on line 9) speciﬁes

the HTTP method used by the operation.

The input and output classes are used on block markup (e.g., <div> and
also <span>), as shown on lines 11 and 17, to indicate the description of the input
or the output of an operation.

The label class is used on textual markup to specify human-readable labels for

services and operations, as shown on lines 2 and 8.

The deﬁnitions above imply a hierarchical use of the classes within the element
structure of the HTML documentation. Indeed, the classes are to be used on nested
elements, in a hierarchy that reﬂects the structure of the service model.

In summary, hRESTS can be used to structure the HTML documentation of a
RESTful Web service according to the WSMO-Lite simple service model. With
this structure in place, we now describe MicroWSMO, a microformat equivalent to
SAWSDL. As shown earlier in this chapter, to annotate a service description with
the appropriate semantics, a model reference on a service can point to a description
of the service’s functional and non-functional semantics; a model reference on an

292

12 Lightweight Semantic Web Service Descriptions

operation points to the operation’s part of the behavioral semantics description; and
a model reference on a message points to the message’s counterpart(s) in the ser-
vice’s information semantics ontology, complemented as appropriate by a pointer to
a lifting or lowering schema mapping.

SAWSDL annotations are URIs that identify semantic concepts and data trans-
formations. Such URIs can be added to the HTML documentation of RESTful ser-
vices in the form of hypertext links. HTML deﬁnes a mechanism for specifying
the relation represented by link, embodied in the rel attribute; along with class,
this attribute is also used to express microformats. In accordance with SAWSDL,
MicroWSMO deﬁnes the following three new types of link relations:
• model indicates that the link is a model reference, as shown in the example

listing in Fig. 12.8 on lines 4 and 13.

• lifting and lowering denote links to the respective data transformations,

such as in the example listing on line 15.

Similarly to how SAWSDL annotations in WSDL can be mapped into the
WSMO-Lite RDFS service ontology (cf. Figs. 12.6 and 12.7), also hRESTS and Mi-
croWSMO descriptions can be transformed into such RDF. Note that hRESTS ex-
tends the WSMO-Lite service model with two properties: hr:hasAddress and hr:has-
Method, applicable to instances of wsl:Operation.

For microformats, the W3C has created a standard called GRDDL (Gleaning
Resource Descriptions from Dialects of Languages, [1]) that speciﬁes how HTML
documents can point to transformations that extract RDF data. In accordance with
GRDDL, an XHTML document that contains hRESTS (and MicroWSMO) data can
point to an XSLT stylesheet7 in its header metadata:

(cid:3)

(cid:2)
<head proﬁle="http://www.w3.org/2003/g/data−view">
<link rel="transformation"

href="http://cms−wg.sti2.org/TR/d12/v0.1/20081202/xslt/hrests.xslt" />

... further metadata, especially page title ...

</head>(cid:4)

(cid:5)

1
2
3
4
5

This header enables Web crawlers and other parsers to extract the RDF form of
the service description data, even if they are not speciﬁcally aware of the hRESTS
and MicroWSMO microformats. The MicroWSMO description from Fig. 12.8 is
embedded in an XHTML document8 that contains also the GRDDL transformation
pointer. Figure 12.9 shows the RDF view of the document.

12.3 Extensions

In this section, we complete the picture of our lightweight SWS approach by sketch-
ing a number of algorithms for processing semantically annotated service descrip-

7The XSLT stylesheet for hRESTS/MicroWSMO is available at http://cms-wg.sti2.org/TR/d12/
v0.1/20081202/xslt/.
8http://cms-wg.sti2.org/TR/d12/v0.1/20081202/xslt/example.xhtml.

12.3 Extensions
(cid:2)

<http://www.wsmo.org/ns/wsmo−lite#> .
<http://cms−wg.sti2.org/TR/d12/v0.1/20081202/xslt/example.xhtml#> .

rdfs:isDeﬁnedBy <http://cms−wg.sti2.org/TR/d12/v0.1/20081202/xslt/example.xhtml> ;
rdfs:label "ACME Hotels" ;
sawsdl:modelReference <http://example.com/ecommerce/hotelReservation> ;
wsl:hasOperation ex:op1 .

<http://www.wsmo.org/ns/hrests#> .
<http://www.w3.org/2000/01/rdf−schema#> .

ex:svc a wsl:Service ;

1 @preﬁx hr:
2 @preﬁx rdfs:
3 @preﬁx sawsdl: <http://www.w3.org/ns/sawsdl#> .
4 @preﬁx wsl:
5 @preﬁx ex:
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21

] ;
wsl:hasOutputMessage [ a wsl:Message ] .

ex:op1 a wsl:Operation;

rdfs:label "getHotelDetails" ;
hr:hasMethod "GET" ;
hr:hasAddress "http://example.com/h/{id}"^^hr:URITemplate ;
wsl:hasInputMessage [

(cid:4)

a wsl:Message ;
sawsdl:modelReference <http://example.com/data/onto.owl#Hotel> ;
sawsdl:loweringSchemaMapping <http://example.com/data/hotel.xsparql>

293
(cid:3)

(cid:5)

Fig. 12.9 RDF data extracted from Fig. 12.8 (with blank nodes in square brackets “[ ]”)

tions, and thus automating the common tasks which are currently performed largely
manually by human operators. Detailed realization of these algorithms remains as
future work. Automation is always guided by a given user goal. While we do not
talk about concrete formal representation for user goals in this chapter, the vari-
ous algorithms need the goal to contain certain speciﬁc information. We describe
this only abstractly, since we view the concrete representation of user goals as an
implementation detail speciﬁc to a particular tool set.

Service Discovery For discovery (also known as “matchmaking”) purposes, our
approach provides functional service semantics of two forms: functionality classi-
ﬁcations and precondition/effect capabilities, with differing discovery algorithms.
With functionality classiﬁcations, a service is annotated with particular function-
ality categories. We treat the service as an instance of these category classes. The
user goal will identify a concrete category of services that the user needs. A discov-
ery mechanism uses subsumption reasoning among the functionality categories to
identify the services that are members of the goal category class (“direct matches”).
If no such services are found, a discovery mechanism may also identify instances
of progressively further superclasses of the goal category in the subclass hierar-
chy of the functionality classiﬁcation. For example, if the user is looking for a
VideoService, it will ﬁnd services marked as VideoSubscriptionService (presum-
ing the intuitive subclass relationships) as direct matches, and it may ﬁnd services
marked as MediaService, which are potentially also video services, even though
this is not directly advertised in the description. For discovery with preconditions
and effects, the user goal must specify the user’s preconditions (requirements) and
the requested effects. The discovery mechanism will need to check, for every avail-
able service, that the user’s knowledge base fulﬁlls the preconditions of the service
and that these preconditions are not in conﬂict with the user’s requirements, and
ﬁnally, that the effect of the service fulﬁlls the effect requested by the user. This

294

12 Lightweight Semantic Web Service Descriptions

is achieved using satisfaction and entailment reasoning. Discovery using function-
ality categorizations is likely to be coarse-grained, whereas the detailed discovery
using preconditions and effects may be complicated for the users and resource-
intensive. Therefore, we expect to combine the two approaches to describe the
core functionality in general classiﬁcations, and only some speciﬁc details using
logical expressions, resulting in better overall usability.

Offer Discovery Especially in e-Commerce scenarios, service discovery as de-
scribed above cannot guarantee that the service will actually have the particular
product that the user requests. For instance, if the user wants to buy a certain
book, service discovery will return a number of online bookstores, but it cannot tell
whether the book is available at these bookstores. Offer discovery is the process of
negotiating with the service about the concrete offers pertinent to the user’s goal.
An offer discovery algorithm uses the behavioral and information model annota-
tions of a Web service to select and invoke the appropriate offer inquiry operations.
In the Web architecture, there is a concept of safe interaction, mostly applied to in-
formation retrieval. In particular, HTTP GET operations are supposed to be safe,
and WSDL 2.0 contains a ﬂag for safe SOAP operations.

Filtering, Ranking, Selection These tasks mostly deal with the non-functional pa-
rameters of a service. The user goal (or general user settings) speciﬁes constraints
and preferences (also known as hard and soft requirements) on a number of differ-
ent aspects of the discovered services and offers. For instance, service price, avail-
ability and reliability are typical parameters for services, and delivery options and
warranty times can accompany the price as further non-functional parameters of
service offers. Filtering is implemented simply by comparing user constraints with
the parameter values, resulting in a binary (yes/no) decision. Ranking, however, is a
multidimensional optimization problem, and there are many approaches to dealing
with it, including aggregation of all the dimensions through weighted preferences
into a single metric by which the services are ordered, or ﬁnding locally-optimal
services using techniques such as Skyline Queries. Selection is then the task of
selecting only one of the ranked services. With a total order, the ﬁrst service can be
selected automatically, but due to the complexity of comparing the different non-
functional properties (for instance, is a longer warranty worth the slightly higher
price?), often the ordered list of services will be presented to the user for manual
selection.

Invocation Service invocation involves the execution of the various operations of
the selected service in the proper order so that the user goal is ﬁnally achieved.
To invoke a single operation, the client uses the information model annotations
plus the technical details from the WSDL or hRESTS description to form the ap-
propriate request message, transmit it over the network to the Web service, and
to understand the response. If multiple operations must be invoked, the client can
use artiﬁcial intelligence planning techniques with functional semantics, and on
RESTful services, the hypermedia graph can guide the client in its invocations,
as the client gets links to further operations in the response to the last operation
invoked.

12.4 Summary

12.4 Summary

295

In this chapter, we presented SAWSDL, and then we introduced WSMO-Lite and
MicroWSMO, two related lightweight approaches to semantic Web service descrip-
tion, evolved from the WSMO framework. WSMO-Lite deﬁnes an ontology for
service semantics, used directly in SAWSDL to annotate WSDLbased services. Mi-
croWSMO and its basis, hRESTS, are microformats that supplement WSDL and
SAWSDL for unstructured HTML descriptions of services, giving WSMO-Lite sup-
port for the growing numbers of RESTful services.

12.5 Exercises

Exercise 1 Referring to the scenario introduced in Sect. 4.3, create a simple tax-
onomy of travel services in RDF or OWL.

Exercise 2 Adopting WSML as language, deﬁne preconditions for BlueHotelSer-
vice described in Sect. 4.3.

Exercise 3 Given the WSDL in Listing 4.13, add annotations from the above tax-
onomy, the precondition, and an ontology.

Exercise 4 Transform the annotated WSDL obtained in Exercise 3 into the
WSMO-Lite RDFS form (make up identiﬁers for the service model components).

Exercise 5 Create from the RESTful version of the BlueHotelService presented
in Sect. 5.3 and HTML description and annotate it to obtain the hRESTS.

Exercise 6 Enhance the obtained hRESTS with MicroWSMO pointers, reﬂecting
the ones used in the SA-WSDL of Exercise 3.

Exercise 7 Transform the annotated HTML obtained in Exercise 6 into the
WSMO-Lite RDFS form.

References

1. Gleaning resource descriptions from dialects of languages (GRDDL). Recommendation, W3C,

(2007). Available at http://www.w3.org/TR/grddl/

2. Khare, R., Çelik, T.: Microformats: a pragmatic path to the Semantic Web (Poster). In: Pro-

ceedings of the 15th International Conference on World Wide Web, pp. 865–866 (2006)

3. Kopecký, J., Vitvar, T., Bournez, C., Farrell, J.: SAWSDL: semantic annotations for WSDL and

XML schema. IEEE Internet Computing 11(6), 60–67 (2007)

4. Kopecký, J., Vitvar, T., Fensel, D.: WSMO-Lite: lightweight semantic descriptions for services
on the Web. CMS WG Working Draft D11 (2009). Available at http://cms-wg.sti2.org/TR/d11/
5. Kopecký, J., Vitvar, T., Fensel, D., Gomadam, K.: hRESTS & MicroWSMO. CMS WG Work-

ing Draft D12 (2009). Available at http://cms-wg.sti2.org/TR/d12/

6. Semantic annotations for WSDL and XML schema. Recommendation, W3C (2007). Available

at http://www.w3.org/TR/sawsdl/

Part IV
Real-World Adoption of Semantic Web
Services

Chapter 13
What Are SWS Good for? DIP, SUPER,
and SOA4All Use Cases

Abstract
In this chapter, we present a selection of extensions and use cases for
Semantic Web Services from successful European research projects, namely ‘Data,
Information, and Process Integration with Semantic Web Services’ (DIP), ‘Seman-
tics Utilized for Process management within and between Enterprises’ (SUPER)
and ‘Service Oriented Architectures for All’ (SOA4All). These projects tackle dif-
ferent aspects of Semantic Web Services, and extend the concepts presented so far
in the book in different directions. Due to the differing nature of this chapter, rather
than following the structure adopted in the previous chapters, we will provide a
general overview in the motivation section, and then dedicate a section to each of
the aforementioned projects. For each project, we will ﬁrst introduce the project
and provide background motivation behind it; we will then present technology en-
hancements delivered through the project and contributions to the extension and
evolution of Semantic Web Services technologies; ﬁnally, we will emphasize one or
more use cases adopted in the project to demonstrate how the technology has been
adopted. The summary section concludes with a summary of the achievements of
these projects.

13.1 Motivation

Scrutinizing how technologies can be employed and extended to meet the needs of
real-world use cases is an important process that enables researchers and profes-
sionals alike to have a better understanding of the potential impact of their work on
future ICT developments and the evolution of economy and society in general.

In this chapter, we will discuss results achieved within three EU-funded research
project that over the past years had a major contribution to the maturing of Se-
mantic Web Services technologies, demonstrating their usefulness and applicability
in various early adopters scenarios. The projects selected are: ‘Data, Information,
and Process Integration with Semantic Web Services’ (DIP, 2004–2007), ‘Seman-
tics Utilized for Process management within and between Enterprises’ (SUPER,
2006–2009), and ‘Service Oriented Architectures for All’ (SOA4All, 2008–2011).
In this chapter, we will survey each of these projects in terms of their motivation
and objectives, an overview of the technical solution, and, where possible, a con-
crete example referring to one of the industrial showcases developed throughout the
project.

D. Fensel et al., Semantic Web Services,
DOI 10.1007/978-3-642-19193-0_13, © Springer-Verlag Berlin Heidelberg 2011

299

300

13 What Are SWS Good for? DIP, SUPER, and SOA4All Use Cases

13.2 Data, Information, and Process Integration with Semantic

Web Services (DIP)

DIP was the ﬁrst large-scale research project pursuing Semantic Web Services top-
ics, and its main outcomes rapidly became foundations for subsequent Semantic
Web Services efforts.1 In fact, the original research work on WSMO (see Chap. 7),
WSML (see Chap. 8) and WSMX (see Chap. 9) were conducted as part of this
project. To avoid repetition of discussions from previous chapters, we will simply
provide a short overview of the technical solution.

13.2.1 Motivation

The DIP project ran from January 2004 to December 2006, and its mission was
to make Semantic Web Services a reality by providing the required infrastructure,
i.e., an open source architecture and a set of exploitable tools. This ﬁrst project in
this area enabled development of a set of prototypes demonstrating such an infras-
tructure and showing how Semantic Web Services could potentially change the way
electronic co-operation and business is conducted, in the same way that the orig-
inal Web revolutionized access to electronic information. The main target of DIP
research was the investigation of the potential of Semantic Web Service technolo-
gies to facilitate more effective and cost-efﬁcient electronic business by drastically
reducing the costs of Enterprise Application Integration (EAI). Speciﬁcally, DIP in-
vestigated the automation of integration or mediation activities through Semantic
Web Services as a scalable and cost effective solution to existing integration prob-
lems.

In the following, we shortly discuss the different research areas addressed by

DIP:
• Information Management DIP employed Semantic Web technologies and de-
veloped a set of new semantic technologies for Web services on top of them to
enable intelligent management of service resources. In particular, DIP provided
the switch paradigm from keyword matching to intelligent search and from infor-
mation retrieval to query answering. DIP also provided solutions for enterprise
information management as exchanges between departments via ontology trans-
lations, deﬁnition of views on documents providing personalization and contex-
tualization of information.

• Enterprise Application Integration DIP developed an integration strategy that
combines the advantages of ad-hoc and global integration strategies. Leveraging
on ad-hoc integration enables the adoption of business needs as the driving force
for the integration process. Leveraging on global integration means the creation
of extensible and reusable integration. In line with this development, DIP adopted
the following goals:

1http://dip.semanticweb.org.

13.2 Data, Information, and Process Integration with Semantic Web Services (DIP)

301

– Business needs to drive the integration process. DIP identiﬁed the major inte-
gration needs in terms of business processes and available information sources.
Moreover, it structured its integration approach around these needs and em-
ployed integration techniques that avoid the disadvantages of ad-hoc integra-
tion, enabling, for example, extensibility and reusability.

– The integration process should be extensible. DIP adopted ontologies to avoid
static ad-hoc integration. Ontologies were used for publishing information re-
garding data sources and for aligning it with business needs. Ontologies were
extensible and thus allowed for the integration process to be easily extended
with the change of business needs.

– The integration process should be reusable. DIP, by pushing for standardiza-
tion, enabled the creation of reusable models and tools for integration. On-
tologies were adopted as the key element to enable reusability in integration
solutions. The architecture itself was designed to be domain independent.
– The integration process should be ﬂexible. DIP, by exploring Semantic Web
Service and advanced techniques for runtime binding of services by means of
service discovery, enabled a ﬂexible ad-hoc integration on the ﬂy, in accor-
dance with changing needs. Integration was not longer a static process where
partners were always the same. Integration became a ﬂexible process, where
according to changes in business needs, new partners could be integrated into
the enterprise.

• e-Commerce DIP investigated potential of Semantic Web Services for
e-Commerce. Web-enabled e-Commerce needs to be available to large numbers
of buyers and suppliers. Its success is closely related to its ability to mediate
a large number of business transactions. Flexibility of e-Commerce cannot be
achieved without multi-standard approaches. In all likelihood, no one standard
will arise that covers all aspects of e-Commerce that would be acceptable in all
vertical markets and all cultural contexts, nor would such a standard free us from
the need to provide user speciﬁc views relating to it and to the content it repre-
sents. In line with these assumptions, DIP developed mediation support dealing
with heterogeneous ontologies and business processes. Furthermore, in business
environments, DIP enabled automatic co-operation between enterprises, by sup-
porting automatic discovery and selection of the optimal Web services based on
business needs.

13.2.2 Technical Solution

As discussed in the previous section, the main technical achievement of DIP is the
ﬁrst implementation of WSMX and its brokerage services. Many WSMX aspects
have evolved since then, but most of the principles in the current version of WSMX
are still in line with the version that was delivered in DIP. Given that WSMX and
related brokerage services were already discussed in Chap. 9, we refer the reader to
that chapter for an in-depth discussion on the DIP technical solution.

302

13 What Are SWS Good for? DIP, SUPER, and SOA4All Use Cases

13.2.3 Use Cases

DIP investigated the adoption of Semantic Web Services as in infrastructure to pro-
vide concrete solutions to real-world business challenges. In particular, DIP applied
results in the areas presented in Sect. 13.2.1 in three scenarios:
• e-Banking While many ﬁnancial institutions offer simple, straightforward infor-
mation portals, only a few offer advanced services such as ﬁnancial aggregators,
where distributed, heterogeneous information is aggregated into a one-stop-shop.
While those applications are quite advanced, the challenge lies in the cost of con-
struction and maintenance. DIP developed a solution supporting aggregation of
stock market information.

• e-Government Nowadays the plethora of available services for citizens and civil
servants provided by public bodies is quite broad. Supporting civil servants and
citizens in ﬁnding the service most appropriate to their needs is not an easy task.
DIP investigated how ontologies, service description, discovery and other related
tools can be integrated in the delivery of real services to citizens and organiza-
tions.

• Virtual Internet Service Provider (VISP) Technology enables service providers
and their partners to reach new customers and expand into new markets, while si-
multaneously reducing the cost of operations. Semantic Web Services can expose
functions and information within service providers systems and allow third party
companies to creatively conﬁgure new bundles of products and services under
their own name. DIP investigated how VISP infrastructures for the B2B market
can offer facilities to compose new virtual services and to support the building of
new virtual enterprise portals.

In this section, we will provide some details on the e-Banking scenario adopted in
DIP and how Semantic Web Services have been adopted in it, a more comprehensive
discussion can be found in [3, 8].

Bankinter,2 the DIP use case partner for the e-Banking scenario, is centered on

ﬁnancial operations for the stock market.

The area of ﬁnancial operations is very heterogeneous and dynamic: it includes
thousands of products, such as stocks, bonds, commodities and derivatives, which
can be combined together. In this area, decision making is inﬂuenced by several
factors coming from different sources, such factors themselves being very dynamic
over time. Thus, this sector is suitable for applying Semantic Web Services tech-
nologies to hinder the difﬁculties its characteristics pose to IT development.

The envisioned application should enable customers of the bank to execute com-
plex operations on the stock market, for instance, to test a condition before executing
an action, such as a buy or sell order, in order to select the right stock to buy. Based
on the user input, the system formulates a goal template which is forwarded to the

2Bankinter is a Spanish industrial bank born from a joint venture by Banco de Santander and Bank
of America. Bankinter is one of the ﬁrst bank exploring digital services for Banking. For more
information, see http://www.bankinter.com.

13.2 Data, Information, and Process Integration with Semantic Web Services (DIP)

303

Fig. 13.1 The e-Banking scenario in DIP. Most important WSMX services involved in the sce-
nario are portrayed in dark gray. The ﬁgure adopts the current version of WSMX architecture and
not the one available at the time of the project

DIP system for the discovery and execution of appropriate Web services. In the
long-term view, Bankinter intends to free customers from the restrictions posed by
custom-built applications; the customer should be allowed to formulate whichever
goal he/she wishes to achieve.

The deployment of WSMX environment as a brokerage system presents a sig-
niﬁcant added value which lies in its capability of composing existing Web services
to achieve more complex functionality. Figure 13.1 presents an overview of the use
case.

The scenario discussed involves three actors:

• Customer as the end user that needs to perform a complex stock market opera-

tion.

• Broker as the intermediary between the customer and the stock market services.
It discovers and aggregates a set of matching services according to customer
needs.

• Service provider, that is, a company that provides services to execute operations
on the stock market and to access decision-support information for these opera-
tions.

According to this classiﬁcation, WSMX covers the role of a broker. Thus, to
support the customer interaction with the broker, the architecture includes a Web
interface supporting the customer in the goal speciﬁcation. The broker is in charge of
discovery, composition and execution of Web services. Therefore, the components
required to instantiate the scenario are:

• Description of stock market services to be provisioned through the system.
• Service discovery engine that matches services with a given goal.
• Service composition engine that enables aggregation of multiple services in case

a single service cannot satisfy the given goal.

304

13 What Are SWS Good for? DIP, SUPER, and SOA4All Use Cases

Fig. 13.2 The Stock Market ontology visualized within WSMT

• Service invocation engine that enables the invocation of services returned by the

discovery engine.

To support the description of the services, two ontologies are used. The ﬁrst
ontology models the stock market domain. This ontology includes concepts such
as stock as well as the related company that issued the stock, the market where the
stock is available, the portfolio that may include the stock, and so on. An overview
of the concepts is depicted in Fig. 13.2, while a WSML fragment representing the
stock concept and stock variation is presented in Listing 13.1. The second ontology
models the processes and operations supported in the stock market domain. For
example, this ontology describes operations such as ‘obtain details of a given stock’
or ‘execute an action on a stock if its value changes or if its value raises’.

Services and goals are deﬁned on top of ontologies as those just mentioned. Ser-
vices correspond to the services available through the Bankinter IT infrastructure,
while goals correspond to a set of primary customer needs identiﬁed within the sce-
nario by Bankinter. Listing 13.2 formalizes the needs of a user that wants to execute
some action (action can refer to a buy order, a sell order, or a request for an alert) on
a speciﬁc stock based on the condition that this stock belongs to top ﬁve variations
on a speciﬁc stock market.

13.3 Semantics Utilized for Process Management Within

and Between Enterprises (SUPER)

In this section, we introduce the SUPER project,3 its originating motivation, the
technical solution adopted, and an example use case. SUPER ran from March 2006
till March 2009 and built upon the results of DIP by layering business processes

3http://www.ip-super.org.

13.3 Semantics Utilized for Process Management Within and Between Enterprises (SUPER)305
(cid:3)

(cid:2)
wsmlVariant _"http://www.wsmo.org/wsml/wsml−syntax/wsml−ﬂight"
namespace { _"http://dip.semanticweb.org/bankinter#",

dc _"http://purl.org/dc/elements/1.1#

}

ontology _"http://dip.semanticweb.org/bankinter/StockMarket.wsml"

concept Stock

isPartOfcompany impliesType (1 1) _string

nonFunctionalProperties

dc#description hasValue "Represents one fraction of one speciﬁc company ownership"

endNonFunctionalProperties

isContinuous impliesType (1 1) _boolean

nonFunctionalProperties

dc#description hasValue "Reﬂects whether or not the stock can be sell /bought in the

Continuous Market"

endNonFunctionalProperties

hasFaceValue impliesType (1 1) _decimal

nonFunctionalProperties

dc#description hasValue "The amount expressed in currency representing the ownership of the

company"

endNonFunctionalProperties

hasPriceValue impliesType (1 1) _decimal

nonFunctionalProperties

dc#description hasValue "The price of the last

transaction for that stock in an speciﬁc

market"
endNonFunctionalProperties
hasStockType impliesType (1 1) _string

nonFunctionalProperties

dc#description hasValue "Speciﬁc types of rights in the company"

endNonFunctionalProperties

hasBestOffer impliesType (1 1) BestOffer

nonFunctionalProperties

dc#description hasValue "The best price that can be found in the market at this point of time.

Two ﬁgures are available : best selling price and best buying price. "

endNonFunctionalProperties

concept StockVariation

hasVariation impliesType (1 1) _decimal

nonFunctionalProperties

dc#description hasValue "The variation of the stock"

endNonFunctionalProperties
hasDirection impliesType (1 1) _string

nonFunctionalProperties

dc#description hasValue "As the variation does not specify the direction of movement, this

attribute indicates whether it

is increasing, steady or decreasing"

endNonFunctionalProperties

hasRelativeVariation impliesType (1 1) _decimal

nonFunctionalProperties

dc#description hasValue "The relative variation of the stock"

(cid:4)

endNonFunctionalProperties

(cid:5)

Listing 13.1 A fragment of the Stock Market ontology summarized in Fig. 13.2

support on top of Semantic Web Services, and by describing business processes
with proper semantics.

13.3.1 Motivation

Historically, IT systems were mainly used for efﬁciently storing and retrieving in-
formation. Over the past decades, automation gradually shifted from such data-

306

13 What Are SWS Good for? DIP, SUPER, and SOA4All Use Cases
(cid:3)

(cid:2)
wsmlVariant _"http://www.wsmo.org/wsml/wsml−syntax/wsml−rule"
namespace {

_"http://dip.semanticweb.org/bankinter/GoalVariationDependentAction.wsml#",
dc _"http://purl.org/dc/elements/11#",
sm _"http://dip.semanticweb.org/bankinter/StockMarket.wsml#",
smp _"http://dip.semanticweb.org/bankinter/StockMarketProcess.wsml#"}

goal

_"http://dip.semanticweb.org/bankinter/GoalVariationDependentAction.wsml"
nonFunctionalProperties

dc#title hasValue "Goal for variation dependent actions"
dc#description hasValue "If the value of a speciﬁed stock belongs to the top ﬁve variations on a

speciﬁed market, then the system execute some action"

endNonFunctionalProperties
importsOntology {
_"http://dip.semanticweb.org/bankinter/StockMarket.wsml",
_"http://dip.semanticweb.org/bankinter/StockMarketProcess.wsml"}

capability

_"http://dip.semanticweb.org/bankinter/GoalVariationDependentAction#capability"
sharedVariables {?marketISIN, ?stockISIN}
/∗
?marketISIN − the name of the market
?stockISIN − the identiﬁer of the stock
∗/
precondition

nonFunctionalProperties

dc#description hasValue "The stock speciﬁed by the user has to belong to the top ﬁve

variations on a speciﬁed market"

endNonFunctionalProperties
deﬁnedBy

?stock [hasName hasValue ?stockName, hasISIN hasValue ?stockISIN] memberOf

sm#Stock and

?market [hasISIN hasValue ?marketISIN, hasTopVariations hasValue ?stock] memberOf

sm#StockMarket.

postcondition

nonFunctionalProperties

dc#description hasValue "Result of the web service is execution of the desired action"

endNonFunctionalProperties
deﬁnedBy

?action[actionType hasValue ?actionType, number hasValue ?number,
customerID hasValue ?customerID, portfolioID hasValue ?portfolioID,
stockISIN hasValue ?stockISIN, market hasValue ?marketISIN] memberOf smp#action.

(cid:5)

(cid:4)

Listing 13.2 A goal for variation dependent actions

driven objectives towards process-oriented support of speciﬁc business activities.
This trend led to the so-called Workﬂow Management Systems (WFMS) by which
pre-deﬁned processes can be automatically enacted. WFMS evolved into Business
Process Management (BPM) techniques that aim at enabling ‘business processes
using methods, techniques, and software to design, enact, control, and analyze op-
erational processes involving humans, organizations, applications, documents and
other sources of information’ [16]. BPM has made more evident the difﬁculties for
obtaining automated solutions from high-level business models, and for analyzing
the execution of processes from both a technical and a business perspective. The SU-
PER project motivation starts from these needs [5]; mediating between the business
level and the IT level requires a signiﬁcant amount of manual work, an approach
which is not only costly, but also error-prone.

13.3 Semantics Utilized for Process Management Within and Between Enterprises (SUPER)307

Semantic (Web Service) technologies can be applied to achieve a feasible level of
automation in the BPM area. SUPER thus proposes to combine Semantic Web Ser-
vices and business processes in order to create one consolidated technology, termed
Semantic Business Process Management (SBPM), which would support both agile
process implementation and sophisticated process management through knowledge-
driven queries issued to the business process space in the form of logical expres-
sions, useful, for instance, to identify activities relevant for compliance with ﬁnan-
cial or environmental regulations or in emergency situations.

13.3.2 Technical Solution

A in-depth discussion of the SUPER approach is given in [13], here we provide a
short overview of the main components of its technical solution.

Semantic Business Process Management aims at accessing the process space of
an enterprise at the knowledge level so as to support reasoning about business pro-
cesses, process composition, and process execution. SBPM builds upon the use of
ontologies as a core component, capturing the required domain information in a for-
mal way to enhance the composition, mediation and discovery of Web services via
Semantic Web services’ techniques implemented in platforms such as WSMX.

SUPER covers all main phases of business process management—design, conﬁg-
uration, execution and analysis—increasing the degree of automation and reuse with
the help of ontology-based semantics. The architecture that supports these phases is
presented in Fig. 13.3. In the following, we will discuss each phase of the life cycle
and how they are supported at the technical level.

13.3.2.1 Design

The fundamental approach adopted in SUPER is to represent both the business per-
spective and the IT system perspective of enterprises using a stack of ontologies,
and to use automatic reasoning for navigating across the typical layers of business
processes:
• Business level (strategic) provides a general overview, and contains a functional
breakdown of a domain usually subdivided into multiple layers which allow nav-
igating through the problem space.

• Business level (operational) is organized into multiple layers which depict con-

crete processes within the enterprise.

• Technical level (processes) is the ﬁrst level for which well-deﬁned semantics are

provided since the models are directly executable by workﬂow engines.

• Technical level (services) is concerned with the actual implementation of pro-

cesses decomposed into activities that can hopefully be automated.

• Technical level (implementation) covers actual implementation artifacts, i.e.,

business functions.

308

13 What Are SWS Good for? DIP, SUPER, and SOA4All Use Cases

Fig. 13.3 SUPER architecture

Fig. 13.4 SUPER stack of ontologies

The stack of ontologies depicted in Fig. 13.4 builds upon the use of the Web Ser-
vice Modeling Ontology (WSMO) (see Chap. 7), as the core Semantic Web Services
conceptualization and Web Service Modeling Language (WSML) (see Chap. 8), as

13.3 Semantics Utilized for Process Management Within and Between Enterprises (SUPER)309

the family of representation languages supporting the speciﬁcation of ontologies,
goals, Web services and mediators.

The integration between the different conceptualizations is provided by the
Upper-Level Process Ontology (UPO) that captures general concepts such as pro-
cess, activity, agent and role which are extensively reused across the subsequent
ontologies. UPO plays an integrating role by linking high-level business conceptu-
alizations to lower-level ones concerning both technical and business details. High-
level business aspects are formalized in a set of ontologies which are represented in
Fig. 13.4 as the Organizational Ontologies cloud. It consists of ontologies capturing
resources, organizational structures, business functions, business policies, business
strategies, etc.

The lower levels of abstraction upon which we have deﬁned the Semantic EPC
(sEPC) and Semantic BPMN (sBPMN) ontologies, which conceptualize EPCs and
BPMN, respectively, incorporate, additionally, the appropriate links to WSMO con-
cepts. These ontologies therefore provide support for two of the main modeling no-
tations currently used in BPM. The Business Process Modeling Ontology (BPMO)
provides a common layer over both sEPC and sBPMN and links them to the rest
of the ontologies from the SUPER stack. BPMO links process models to organi-
zational information as conceptualized in the Organizational Ontologies. It is also
linked to the Behavioral Reasoning Ontology (BRO) whose aim is to support the
composition of processes by reasoning about their behavior. Finally, BPMO enables
the transformation of business processes modeled using different notations in an
executable form.

13.3.2.2 Conﬁguration

The outcome of the design phase is in the form of business process models that
deﬁne a control ﬂow between activities, but usually lack speciﬁc data ﬂow infor-
mation and references to particular implementations of business functions. SUPER
uses WSMO as the ontological framework to describe the semantics of services in
terms of their capabilities, data models and behavioral interface, i.e., how they need
to be invoked. Such descriptions can be used to deﬁne services and to retrieve imple-
mentations thereof that match the requirements formulated by a client as a WSMO
goal. Similar concepts can be used to describe the functionality required by the
tasks composing a process, and the functionality services provide. Finally, in order
to support the execution of business processes, WSMO is complemented by BPEL
[6], given its extensive support and use within the industry. Several approaches exist
within the literature for the translation of conceptual models expressed in notations
such as BPMN to an executable model such as BPEL. They are supported by ontolo-
gies through the deﬁnition of semantic business process models (sEPC, sBPMN, and
BPMO ontologies). The Semantic BPEL (sBPEL) ontology [11] formalizes BPEL
and includes additional constructs linked to WSMO so as to support the mediation
between heterogeneous data and processes, and the invocation of goals as opposed
to explicitly speciﬁed Web services. Different transformations have been deﬁned
between these different conceptualizations.

310

13 What Are SWS Good for? DIP, SUPER, and SOA4All Use Cases

SUPER investigated two strategies for binding implementations to executable

process models during conﬁguration:
• WSMO goals as activity implementations Using WSMO goals as activity im-
plementations requires a middleware that implements the WSMO model follow-
ing the SEE reference architecture (e.g., WSMX, see Chap. 9). Goals can be used
to query for suitable service implementations, following an approach similar to
query-by-example (QBE) in databases. Depending on the completeness of the
formulated goal the result of such a query can be either a matching service (static
binding), or a ranked list of services implementing the requested functionality. In
the latter case, the actual binding is delayed until the execution phase, when the
execution engine picks the best matching service implementation during runtime
(late binding).

• WSDL services as activity implementations Instead of connecting activities
with WSMO Goals, BPEL4SWS also supports static binding to conventional Web
services.

13.3.2.3 Execution

The use of Semantic Web Services provides the ﬂexibility required in the BPM ex-
ecution phase. At runtime goals can be bound to speciﬁc Semantic Web Services
selected on the basis of the existing conditions and informed by contextual knowl-
edge, which includes monitoring data. Furthermore, since services are described se-
mantically, both functional and non-functional properties are formally represented
using domain ontologies.

In a nutshell, the use of Semantic Web Services provides the following beneﬁts

from a process execution perspective:
• Process models are independent of the invoked partner services. If a partic-
ular partner is not available, the execution middleware chooses a different
functionally-equivalent service without the need to change the process model and
its deployment information.

• Process models are independent of the internal data model of the partner. The
process model has its own semantically annotated data model. If the partner’s
data model differs from that, semantic models help to bridge this gap.

• Partner services can be selected based on business aspects. Non-functional infor-
mation about cost, quality of service, trust, legal constraints, etc. can be taken into
account so that the selected service is most suitable from a business perspective.

13.3.2.4 Analysis

SUPER deﬁned a stack of ontologies that connect log information to higher-level
conceptual models about business processes, organizational structures, business
goals and strategic aspects. In particular, the Events Ontology provides a sharable

13.4 Service Oriented Architectures for All (SOA4All)

311

conceptual model for capturing business processes logs, whereas Core Ontology for
Business pRocess Analysis (COBRA) connects it to the business level.

Important efforts have been devoted to enhancing mining techniques within SU-
PER [4], and the uses of semantic technologies have already proven their beneﬁts.
So far, the techniques developed as part of the ProM framework [17] have focused
on enhancing existing ones with semantics.

13.3.3 Use Cases

SUPER developed two different showcases on the topic of managing IT processes
in the telecommunication sector.

• Telecoms Framework and Ontology Within this use case, SUPER developed a
series of domain and process ontologies relevant to the telecommunication sector,
together with a semantic framework for telecommunication. The major outcome
of this endeavor is the telecom framework YATOSP (Yet Another Telecom On-
tology, Service and Process framework) which builds upon established Telecom-
munications Business Area artifacts such as TMF’S NGOSS.

• Telecoms Semantic Business Process Applications Three telecommunication
use cases covering the ﬁeld of ﬁxed telephony, trafﬁc routing and management
(through VoIP communications) and mobile environments with innovative de-
vices and technologies have been selected for this particular use case and the
project developed several demonstrators showcasing the core technology.

SUPER use cases material are protected by conﬁdentiality, interested readers
should contact the use case owners or the project coordinator, via the project Web
site to gain access to additional material.

13.4 Service Oriented Architectures for All (SOA4All)

In this section, we present the European research project SOA4All4 launched in
2008 whose aim is to provide Semantic Web Services technology that is feasibly
applicable in large-scale, open and dynamic environments where an arbitrarily high
number of parties are providing and consuming functionality as services. SO4All is
a key contributor to the research on lightweight semantics approaches presented in
Chap. 12. In this chapter, we will focus on the technical infrastructure required to
realize the SOA4All Service Web vision, and exemplify its application through one
of the three use cases of the project.

4http://www.soa4all.eu.

312

13 What Are SWS Good for? DIP, SUPER, and SOA4All Use Cases

13.4.1 Motivation

One of the most prominent IT trends of the last decade is the shift towards service-
oriented IT architectures (SOA) [7]. SOA speciﬁes a set of loosely coupled services
whose interfaces are published, discovered and invoked over the Internet, along with
their interactions. It has been adopted by the industry not only as a technological but
also a business trend, promising to close the gap between what companies require
and what IT is able to deliver. The aim is to achieve a more ﬂexible IT infrastructure
that can react to business changes faster than the classic monolithic IT systems.
Similarly, using Web standards it is easier for companies to interact with each other,
forming business ecosystems. Surveys and experience show, however, that SOA is
primarily used for internal integration and much less for external integration, in
particular, only very few companies offer their (internal) services to other parties
such as their customers. This mind set is now changing as some, predominantly
U.S.-based companies such as Yahoo, eBay, Amazon, and Google are exposing their
IT services to the Web, allowing third parties to integrate these services to build new
applications in the so-called ‘mash-ups’.

Parallel to the internal SOA transformation within large enterprises, the Web
has continued its path of success, becoming the dominant information medium for
consumers and enterprises alike. It has helped many small and medium enterprises
become globally visible in a world dominated by global corporations. Consumers
have been dazzled by the new means of participation brought forward by the advent
of Web 2.0. Technologies that further simplify user contributions such as blogs and
tagging have unleashed the power of communities with initiatives such as Wikipedia
convincingly demonstrating the ‘wisdom of the crowds’ in creating the world’s
largest encyclopedia.

Advances in communication technologies provide bandwidth that allow users to
interact with Web applications similarly to how they interact with desktop appli-
cations, facilitating the formation of new business models such as ‘software as a
service’ with minimal installation costs and rich Internet applications (RIA).

Early-adopters like Amazon have picked up on these trends and started to expose
and offer their internal applications as Web services to other businesses. Never-
theless, today, the Web contains only around 30,000 Web services5—a minuscule
amount compared to the 30 billion Web pages constituting its content. In conse-
quence, SOA is still largely an enterprise speciﬁc solution exploited by, and located
within, large corporations and their supply chains. As mobile, wireless, optical and
broadband communication infrastructures become ever bigger and more interdepen-
dent, we expect the number of Web services to grow exponentially in years to come.
In particular:

• More companies will publish their offerings as services accessible through the
Web, inspired by the success of examples such as Amazon, eBay and Yahoo.

5http://seekda.com.

13.4 Service Oriented Architectures for All (SOA4All)

313

• Web 2.0 has popularized concepts such as mash-ups and RSS and thereby illus-
trated comparatively simple means for business networking and business ﬂexibil-
ity.

• Efforts to turn the Web into a general platform for accessing and interconnect-
ing arbitrary devices and services are maturing and may turn billions of diverse
devices such as household appliances into accessible Web services.

• Following the ‘mechanical turk’ paradigm, humans may act on behalf or as part
of a Web service to acquire the input data required to perform a certain task.

Hence, there is a need to master the very large—we must be able to handle the
complexity of these systems conﬁdently as well as provide them with learning ca-
pabilities and self-organizing functions. Crucially, systems and software must be
secure, robust, dependable and optimized in terms of functionality in order to cater
to multiple audiences.

SOA4All aims to realize a world where billions of parties are exposing and con-
suming services via advanced Web technology. The outcome of the project will be
a comprehensive framework and infrastructure that integrates four complementary
technical advances into a coherent and domain-independent service delivery plat-
form:
• Web principles and technology as the underlying infrastructure for the integration

of services at a world wide scale.

• Web 2.0 as a means to structure human–machine cooperation in an efﬁcient and

cost-effective manner.

• Semantic technologies as a means of abstracting from syntax to semantics as

required for meaningful service discovery.

• Context management as a way to process, in a machine understandable way, user
needs that facilitates the customization of existing services for the needs of those
users.

13.4.2 Technical Solution

SOA4All realizes a service delivery platform that is optimized and tailored to
the needs of Web services (both traditional WS-* stack-based services, as much
as REST APIs), which can be expanded to support arbitrary types of exposable
functionalities, such as mobile services, sensors and aggregators, and hardware re-
sources. As such, the service delivery platform will provide the core provisioning
and consumption functionalities for emerging XaaS (“Everything as a Service”) in-
frastructures. A more comprehensive discussion can be found in [9].

In the remainder of this section, we present the overall architecture of SOA4All.
This architecture comprises the following main components: SOA4All Studio, as
user front-end, Distributed Service Bus, Platform Services, and Business Services
(third party Web services and light-weight processes). Figure 13.5 shows a high-
level depiction of these core elements and their relationships.

314

13 What Are SWS Good for? DIP, SUPER, and SOA4All Use Cases

]
9
[

e
r
u
t
c
e
t
i
h
c
r
a

l
l
a
r
e
v
o
l
l

A
4
A
O
S

5
.
3
1

.
g
i
F

13.4 Service Oriented Architectures for All (SOA4All)

315

13.4.2.1 Service Bus

The Distributed Service Bus is at the core of the service delivery platform, as the
core communication and integration infrastructure. The DSB augments traditional
enterprise service bus technology (ESB [15]) towards large-scale, open, distributed,
and hence Web-scale, computing environments. The extensions of the service bus
infrastructure include, for this purpose, the implementation of distributed service
registries, the integration of the bus realization with established Grid-aware mid-
dleware for decentralized deployments, and the enhancement of the communication
and coordination protocols by means of semantic spaces. From a deployment per-
spective, the problems to be solved become of similar nature to those raised when
programming, deploying, securing, monitoring, and adapting a distributed applica-
tion on a computing grid infrastructure.

The enterprise service bus core adopted in SOA4All is based on PEtALS.6 And
ﬁnally, the Web-style publish-and-read infrastructure is provided by the so-called
semantic spaces that signiﬁcantly increase the scalability of the bus in terms of com-
munication and coordination of distributed and autonomous services [12]. Semantic
spaces, introduced in Chap. 10, are a novel type of communication platform that has
recently gained momentum in the middleware community, as a response to the rais-
ing challenges of data sharing and service coordination in large-scale, distributed,
open and highly dynamic Web environments.

In SOA4All, semantic spaces are realized as a virtualization layer on top of dis-
tributed but tightly coordinated semantic repositories. The semantic spaces offer
a simple but powerful set of operations for publishing RDF statements, querying
SPARQL [14] end-points, and coordinating actions via pattern-based notiﬁcation
services. More pragmatically spoken, service prosumers can subscribe to particu-
lar patterns that they would like to match within the wealth of semantic data (RDF
graphs). Semantic patterns are triple patterns or graph patterns, as they are supported
by most RDF query languages, including SPARQL. Upon publication of matching
sets of statements, the subscriber is notiﬁed and can proceed with its own workﬂow.
In terms of data management, semantic spaces moreover provide a means for cre-
ating virtual containers in the form of the so-called subspaces or federations. The
latter are temporary read-only views over multiple subspaces, comparable to views
in relational databases across different tables. Subspaces and federations are used
to create dedicated interaction channels that increase local scalability by naturally
grouping collaborating services and related data. The implementation of the seman-
tic space infrastructure is based on well-established P2P technology and is deployed
on the same grid-aware middleware as the service bus nodes. In that way, the space
nodes and bus nodes are co-existent and coordinated resources in the same grid in-
frastructure. From a usage point of view, semantic spaces are exploited to realize
many of the large-scale data sharing scenarios for which the volumes of semantic
data that has to be processed is likely to exceed the numbers that semantic reposi-
tories can currently handle. SOA4All relies on semantic spaces to incorporate var-
ious types of repositories for service annotations, goals or process descriptions, as

6PEtALS [10] is an open source ESB, more information is available at http://petals.ow2.org/.

316

13 What Are SWS Good for? DIP, SUPER, and SOA4All Use Cases

Fig. 13.6 SOA4All Studio: WSMO-Lite Editor (provisioning platform)

memory infrastructure for shared access to semantically described monitoring data
and user proﬁles, and most of all as alternative communication channel that en-
hances the traditionally message-oriented service bus with features for anonymous
and asynchronous service coordination based on RDF statements; this aspect will be
described in more detail in the section on processes that follows, in particular in the
context of mash-ups. It is important to note that the complementary communication
facilities of the semantic spaces are offered to all services and users as an inte-
grated service of the DSB, without requiring the maintenance of additional access
points. In other words, the DSB is conceptualized to provide the core infrastructure
services (integration, communication and storage) of SOA4All in an all-in-one so-
lution. This is an important principle for a scalable service delivery platform, as it
allows any type of communication efﬁciently and transparently by means of shar-
ing or exchanging any type of data in between any type and number of distributed
parties.

13.4.2.2 SOA4All Studio

The SOA4All Studio delivers a fully Web-based user front-end that enables the
creation, provisioning, consumption and analysis of services that are published to
SOA4All (Fig. 13.6). It consists of three subcomponents that target the three dif-
ferent service management tasks: provisioning at design time, consumption, and
analysis at runtime.
• The Provisioning Platform has two main purposes. First, it provides the tools
to annotate services, either WSDL services via WSMO-Lite, or REST APIs via

13.4 Service Oriented Architectures for All (SOA4All)

317

MicroWSMO (cf. Chap. 12 for more details). Second, it incorporates a Process
Editor that allows users to create, modify, share, and annotate executable pro-
cess models based on a light-weight process modeling language. SOA4All pro-
vides such a language as a considerably simpliﬁed subset of the Business Process
Modeling Notation (BPMN1.2, [18]) for the abstract parts, and a subset of the
Business Process Execution Language (WS-BPEL2.0, [6]) for executable parts.
In this way, SOA4All hides much of the service composition complexity whilst
providing sufﬁcient notational semantics to understand the interactions between
services being composed, and sufﬁcient expressive power for the users to con-
struct useful compositions.

• The Consumption Platform is the gateway for users to the service world when
they act as consumers. The platform allows them to formalize their desires in
several ways, deﬁning and reﬁning goals that can be used to discover and in-
voke the services that fulﬁll their needs. The platform stresses personalization by
making use of contextual factors to offer a more suitable service consumption to
the users, and to adapt the services and the platform based on past use, e.g., by
recommending goals for different users in varying situations.

• The Analysis Platform obtains information (monitoring events) from the monitor-
ing subsystem of the bus and performs processing in order to extract meaningful
information. Monitoring events should come from data collectors that perform
basic aggregation from distributed sources in the service delivery platform. Data
collectors are installed at the level of the bus (message exchange monitoring), the
grid middleware (node monitoring in terms of storage or processing load), and
the execution engine (service access and process invocation monitoring).

13.4.2.3 Platform Services

The platform services deliver discovery, ranking and selection, composition and
invocation functionality, respectively. These components are exposed via the
SOA4All Distributed Service Bus as Web services and hence consumable as any
other published service. The distinguishing factor between platform services and
other Web services is the fact that they provide the core functionality required to
realize the service platform. A priori, the set of platform services and their roles
and interfaces is aligned with recent research in the area of Semantic Execution
Environments and Semantic Web services (e.g., the OASIS SEE Technical Com-
mittee).7 Platform services are mostly used by the SOA4All Studio to offer clients
the best possible functionality, while their combined activities (i.e., discovery, selec-
tion, composition and invocation) are coordinated via the Distributed Service Bus.
The ensemble of DSB, SOA4All Studio and platform services delivers the fully
Web-based and Web-enabled service experience of SOA4All: global service deliv-
ery at the level of the bus, Web-style service access via studio, and advanced service
processing, management and maintenance via platform services.

7http://www.oasis-open.org/committees/semantic-ex.

318

13 What Are SWS Good for? DIP, SUPER, and SOA4All Use Cases

13.4.2.4 Business Services (Web Services) and Processes

In the corners of Fig. 13.6, semantic service descriptions and processes (composed
services) are depicted. They are created and processed by means of the SOA4All
infrastructure. First, SOA4All enables available Web services that are exposed ei-
ther as RESTful services, or as traditional WS-* stack-based services in the form of
WSDL endpoints [2] (marked with (3) and (4) in Fig. 13.6). Such services are re-
ferred to as invocable third-party business services, and are enhanced by SOA4All
in terms of automation, composition and invocation via the lifting to the semantic
level. Second, Fig. 13.6(1) depicts the semantic annotations of the business services,
the so-called Semantic Web services. The semantic descriptions are published in the
service registry that is shipped as a platform service, and used for reasoning with
service capabilities (functionality), interfaces and non-functional properties, as well
as context data. These semantic descriptions are the main enablers of the automa-
tion processes related to Semantic Web services. Third, marked as (2), light-weight
processes and mash-ups are shown. They are the basis for the realization and exe-
cution of composed services. Processes in SOA4All are orderings of Semantic Web
services, goal descriptions with associated constraints, data, and control ﬂow infor-
mation, respectively. As stated earlier in this paper, a goal is a formal speciﬁcation
of the objective that a user would like to have performed, and as such it yields an
implicit abstraction over the Web services (REST or WS-* stack-based) that needs
to be executed. Semantic descriptions of processes are published in form of RDF
graphs in the shared semantic space infrastructure, and as such become a public
common and building block for service computing. In contrast to fully-ﬂedged pro-
cesses, a mash-up is a data-centric speciﬁcation over a collection of REST services.
A further characteristic of mash-ups is the fact that they are almost entirely exe-
cutable in semantic spaces. By being data-driven, their composition is enabled by
the coordinated access to shared data in semantic spaces. Although being compara-
bly simple, mash-ups thus provide a very promising approach to Web-style service
computing, a pre-requisite for large-scale service economies.

13.4.3 Use Cases

SO4All investigated the adoption of SOA in infrastructure to provide concrete solu-
tions to real-world business challenges. In particular, SO4All applied results in the
areas presented on three scenarios:
• End-User Driven Enterprise Integration To investigate potentials and chal-
lenges of the integration between new, dynamic, end-user driven service con-
struction and delivery platforms, on the one hand, and existing Enterprise SOA
infrastructures, on the other. To demonstrate the feasibility of the end-user service
construction in the established area of Enterprise SOA.

• Twenty First Century Telecom Services To evaluate how the discovery, inte-
gration and use of the capabilities of Telecom operators can be done much more

13.4 Service Oriented Architectures for All (SOA4All)

319

effectively, reducing the cost and time of creating mash-ups and allowing a much
more ﬂexible approach to integration with other services.

• Customer-to-Customer e-Commerce To provide a reference service applica-
tion that supports the setup of e-Commerce applications in customer-to-customer
(C2C) exchange settings, by integrating services over the Web.

In this section, we will provide some details on the e-Commerce scenario adopted
in SOA4All and how SOA4All structures have been adopted in it. A more compre-
hensive discussion can be found in [1]. The scenario is centered around the provision
of end-customers means to create ﬂexible and highly customizable e-Commerce
Web sites. In order to do this, users will use a C2C e-Commerce framework, which
operates on an ISP’s infrastructure and is accessible to its customers. This frame-
work will add e-Commerce-speciﬁc functionality such as a product catalogue, order
management, invoicing, and basic payment services. Other functionalities, such as
ﬁnding a service and composing of process, will be more generic and supported
by the SOA4All service delivery platform. A dedicated service broker, offering a
search engine and a service marketplace for value-added (composed) services, will
provide access to third-party services.

The e-Commerce application framework will enable consumers to conduct busi-
ness with other customers. This approach is similar to popular Web 2.0 platforms
(e.g., Facebook or Google Checkout) where the company provides a framework that
allows customers to create solutions for C2C business. What is different in the pre-
sented scenario compared to existing solutions is that the scenario will entirely focus
on providing an easy way of using third party services (solutions) offered through
the framework.

End-customers are able to use various SOA4All-enhanced tools offered through
the framework to build their own end customer applications. For example, the frame-
work will include typical Web shop functionalities such as a shopping cart feature
and an access to payment providers using the SOA4All service orchestration and
communication facilities.

The scenario is developed around three actors (see Fig. 13.7 due to [1]):

Reseller who wants to generate income on various popular Web 2.0 sites and uses
SOA4All to connect services of various partners in order to expose product infor-
mation to Facebook, Twitter, her own Web shop, etc.

Seller who wants to increase sales by offering Web services, allowing resellers to

retrieve a product list and to order a speciﬁc product.

Buyer who visits the reseller’s Facebook page, sees some personalized products
and decides to buy one of them.

In the following, we describe how the scenario can be enabled by SOA4All tech-
nologies and how the different actors interact with them. Figure 13.8 depicts the
scenario.

Sellers are afﬁliated to different companies which are all producing products
from the textile industry, reaching from footwear t-shirts for all seasons and covering
both male and female apparel. They are responsible for the e-Commerce part of
their companies and need simple means to provide and consume services. To enable

320

13 What Are SWS Good for? DIP, SUPER, and SOA4All Use Cases

Fig. 13.7 Roles and process steps of the e-Commerce use case scenario

interaction between buyers and the e-Commerce back-end, they provide a simple
service that allows to
• Retrieve a list of products and product descriptions.
• Request information about the price and availability of a product.
• Place a product order.

Services can be both WSDL and REST-based. Once created, they can be reg-
istered in the SOA4All platform through the SOA4All Studio. Sellers use the
SOA4All tools to annotate their services and describe them graphically with some
semantic information based on common e-Commerce ontologies, such as eCl@ss8
for product categorization and the GoodRelations9 for details on their product def-
initions and order services. They can do all of this using the graphical components
of SOA4All—without any knowledge of the technologies behind the scenes—just
by using drag & drop to annotate their service elements. Afterwards they click the
save button to add the service to SOA4All.

The reseller registers a business to the framework, which allows her to buy and
sell products. The reseller is skilled in IT and Web technologies: she uses var-
ious Web 2.0 platforms including Facebook, Twitter and even an alpha version
of Google Wave and even owns a small Web shop where she adds textile prod-
ucts manually from time to time. However, via her Web shop she is only mak-
ing a limited number of sales and the product descriptions are usually outdated.

8http://www.eclass-online.com.
9http://purl.org/goodrelations.

13.4 Service Oriented Architectures for All (SOA4All)

321

Fig. 13.8 Graphical representation of the customer-to-customer e-Commerce scenario [1]

She spends most of her time that she would like to instead invest into her Web
shop updating prices and availabilities or to remove and add products. Also she
has no way of automatically aligning her offered products with the Web 2.0 plat-
forms she is using. For example, she also has created an eBay shop to sell and
auction some of her products, but needs to manually synchronize the two shops.
The reseller wants to change this and to do this more efﬁciently, thus saving time
and being able to invest it in more sales opportunities. She wants to be able to au-
tomate product listings, being convinced that adding her products to her Web 2.0
appearances would signiﬁcantly increase her sales. However, automating things is
a highly technical work, and even if she develops a piece of software to connect
her shop to the product data of her supplier, she would make herself bound to this
supplier and would not be as ﬂexible any more as things tend to be highly con-
nected.

The reseller visits the SOA4All Studio and creates a user proﬁle with the
SOA4All Proﬁle Editor. She then starts searching for suitable services using the
SOA4All Discovery Platform and ﬁnds many services related to products and prod-
uct catalogs such as a service from Amazon and other sellers. She has the chance
to reﬁne her search and to ﬁlter the result set to those services related to the textile
domain. The reseller also has the chance to see comments and feedback left by other
users who tried them before.

The SOA4All recommendation system is capable of automatically recognizing
her interests by analyzing her past behavior and relating it to other SOA4All users

322

13 What Are SWS Good for? DIP, SUPER, and SOA4All Use Cases

within the Consumption Platform. In this way, SOA4All is able to ‘recommend’
her services that are appreciated by users with a similar proﬁle. She looks at the
product service result list and gets an ordered list of four different services, in which
the fourth one was rated not so positively, while the ﬁrst three have received good
feedback. She ﬁnally decides to use the three different services coming from the
sellers introduced before, and bookmarks them to her favorite list.

Having selected some services she wants to achieve, the reseller wants to connect
them to her Web shop. One of the services offers more available end points. She
selects all possible services at design time and leaves it to SOA4All to select the
best one based on the current context. For example, SOA4All will select one of the
service end points automatically during runtime.

Alternatively, the reseller can also select goals instead of services. She uses a pre-
deﬁned template from another SOA4All user, which allows her to take advantage of
existing process templates without having to start from scratch. She is recommended
to use a mediation & aggregation service for merging and aggregating the three
product services including some descriptions. Once she has done so, she uses the
process editor again to create a second process which forwards an order from her
Web shop to the product manufacturer service, as soon as an order arrives. She
executes her process to test it and she can directly see the results of her execution.

The reseller can use also SOA4All to show her product information on some
well known Web 2.0 platforms, thus presenting her products to a large number of
people. She also wants to ensure that people that visit her Facebook proﬁle see the
products belonging to their current context. For example, she does not want her
Facebook proﬁle to advertise a winter jacket in the summer time, but she might
want to advertise clothes with special Facebook logos.

Although the buyer does not realize that SOA4All is used under the hood, he

beneﬁts greatly from the new functionalities of SOA4All.

Context Awareness The buyer will see products that are ‘made for him’, or are
more precisely matching his proﬁle. He will not see any winter dresses for women
in the summer time.

Always up-to-date There is nothing worse than ordering a product, paying and
then getting a notiﬁcation that the product is not available any more. With
SOA4All, the buyer can be sure that all product data is up-to-date and available.
Process Optimization The buyer indirectly beneﬁts from the SOA4All template
generator which will optimize the order process over time to match the require-
ments of the users. This will shorten the time needed for him to buy products and
will increase his shopping experience.

Reliability and Trust As the reseller used the rating facilities of SOA4All, she
only added product sellers that are reliable. Furthermore, in case the services fail
for some reasons, the execution engine is able to substitute them to complete
the execution. The buyer therefore directly beneﬁts from this increased reliabil-
ity.

13.5 Summary

13.5 Summary

323

In this chapter, we gave an overview of extensions and use cases for Semantic Web
Services from three successful European research projects, namely Data, Informa-
tion, and Process Integration with Semantic Web Services (DIP), Semantics Utilized
for Process management within and between Enterprises (SUPER) and Service Ori-
ented Architectures for All (SOA4All). Other interesting extensions and results have
been provided in projects such as SWING,10 SemanticGov11 and SHAPE.12 Inter-
ested readers can refer to these projects Web sites to gather further information.

References

1. Abels, S., Schreder, B., Villa, M., Zaremba, M., Sheikhhasan, H., Puram, S.: eCommerce

framework infrastructure design. SO4All Project Deliverable D9.2.1. Tech. rep. (2009)

2. Chinnici, R., Haas, H., A.L.J.J.M.D.O., Weerawarana, S.: Web services description language

(wsdl) Version 2.0 Part 2: adjuncts. W3C Recommendation (2007)

3. Cobo, J.M.L., Losada, S., Cicurel, L., Bas, J.L., Bellido, S., Benjamins, V.R.: Ontology Man-
agement in E-banking Applications. In: Hepp, M., Leenheer, P.D., de Moor, A., Sure, Y. (eds.)
Ontology Management. Semantic Web and Beyond Computing for Human Experience, vol. 7,
pp. 229–244. Springer, Berlin (2008)

4. de Medeiros, A.K.A., Pedrinaci, C., van der Aalst, W.M.P., Domingue, J., Song, M., Rozinat,
A., Norton, B., Cabral, L.: An outlook on semantic business process mining and monitoring.
In: Meersman, R., Tari, Z., Herrero, P. (eds.) OTM Workshops (2). Lecture Notes in Computer
Science, vol. 4806, pp. 1244–1255. Springer, Berlin (2007)

5. Hepp, M., Leymann, F., Domingue, J., Wahler, A., Fensel, D.: Semantic business process
management: a vision towards using semantic web services for business process management.
In: Lau, F.C.M., Lei, H., Meng, X., Wang, M. (eds.) ICEBE, pp. 535–540. IEEE Computer
Society, Los Alamitos (2005)

6. Jordan, D., Evdemon, J.: Web Services Business Process Execution Language Version 2.0.

OASIS Standard (2007)

7. Josuttis, N.M.: Soa in Practice: The Art of Distributed System Design, 1st edn. O’Reilly Me-

dia, Sebastopol (2007). http://www.worldcat.org/isbn/0596529554

8. Kleczek, D., Losada, S., Bas, J.L., Bellido, S., Contreras, J., Montes, M.M.: WSMO descrip-

tions of application 2. DIP project deliverable D10.8. Tech. rep.

9. Krummenacher, R., Norton, B., Simperl, E.P.B., Pedrinaci, C.: Soa4all: enabling Web-scale
service economies. In: ICSC, pp. 535–542. IEEE Computer Society, Los Alamitos (2009)
10. Louis, A.: Build an SOA application from existing services—Put heterogeneous services
together with the Petals ESB. JavaWorld.com (2006). http://www.javaworld.com/javaworld/
jw-10-2006/jw-1011-jbi.html

11. Nitzsche, J., Wutke, D., van Lessen, T.: An ontology for executable business processes. In:
Hepp, M., Hinkelmann, K., Karagiannis, D., Klein, R., Stojanovic, N. (eds.) SBPM. CEUR
Workshop Proceedings, vol. 251. CEUR-WS.org (2007)

12. Nixon, L.J.B., Simperl, E.P.B., Krummenacher, R., Martín-Recuerda, F.: Tuplespace-based
computing for the semantic web: a survey of the state-of-the-art. Knowledge Engineering
Review 23(2), 181–212 (2008)

10http://www.swing-project.org.
11http://www.semantic-gov.org.
12http://www.shape-project.eu.

324

13 What Are SWS Good for? DIP, SUPER, and SOA4All Use Cases

13. Pedrinaci, C., Domingue, J., Brelage, C., van Lessen, T., Karastoyanova, D., Leymann, F.:
Semantic business process management: scaling up the management of business processes.
In: ICSC, pp. 546–553. IEEE Computer Society, Los Alamitos (2008)

14. Prud’hommeaux, E., Seaborne, A.: SPARQL query language for Rdf. W3C Recommendation

(2008)

15. Schmidt, M.T., Hutchison, B., Lambros, P., Phippen, R.: The enterprise service bus: making

service-oriented architecture real. IBM Systems Journal 44(4), 781–797 (2005)

16. van der Aalst, W.M.P., ter Hofstede, A.H.M., Weske, M.: Business process management: a sur-
vey. In: van der Aalst, W.M.P., ter Hofstede, A.H.M., Weske, M. (eds.) Business Process Man-
agement. Lecture Notes in Computer Science, vol. 2678, pp. 1–12. Springer, Berlin (2003)
17. van Dongen, B.F., de Medeiros, A.K.A., Verbeek, H.M.W., Weijters, A.J.M.M., van der Aalst,
W.M.P.: The prom framework: a new era in process mining tool support. In: Ciardo, G., Daron-
deau, P. (eds.) ICATPN. Lecture Notes in Computer Science, vol. 3536, pp. 444–454. Springer,
Berlin (2005)

18. White, S.: Business process modeling notation. OMG Standard (2009)

Chapter 14
Seekda: The Business Point of View

Abstract
Industry is slowly picking up on the use of semantic technologies within
their systems. In this chapter, we describe how these technologies are employed by
seekda, a company focused on Web services. The aim of seekda is to ease the search,
interoperability and bundling of services and make them readily usable in various
areas, for example, in e-Tourism. This is done through the use of a crawler, a search
portal and a service bundle creator. An application of these technologies within a
seekda product—seekda! connect—is also described.

14.1 Motivation

Since its inception, the Internet grew very rapidly. From a Web of simple html pages,
it has evolved into a Web of multimedia content, followed by a Web of services.
These services range from simple ones, such as sending text messages over mo-
bile phones, to more sophisticated ones, like booking a ﬂight and purchasing items.
In parallel to this evolution, software development companies moved from creat-
ing monolithic applications to more service-centric architectures where the focus
is given on the reuse of software artifacts rather than rebuilding them from scratch.
This led to the birth of Service Oriented Architectures (SOA) [3]. The basic principle
is that of having services that are readily available for organizations. Such organiza-
tions are not interested in the implementation of the services they require, but rather
the descriptions of the services which deﬁne what can be provided by the service.
Furthermore, the combination of such services leads to the fulﬁllment of a more
complicated requirement that cannot be obtained by a simple atomic service—here
is where service processes come into play. Processes combine services together into
a workﬂow to achieve some predeﬁned functionality. Generally, an organization has
what is called a Business Process which is enacted as a Workﬂow Process with spe-
ciﬁc (automated or non-automated) services that fulﬁll higher-level business needs.
Automated services need not be legacy services within the organization itself, but
may also be provided by some external entities. In a nutshell, the basic idea is that
services are registered by a provider to a service broker. Organizations then search
for services through the service broker and eventually bind the needed services with
the provider. This scenario is depicted in Fig. 14.1.

Even though this looks like a simple scenario, various problems arise in realiz-

ing it:

D. Fensel et al., Semantic Web Services,
DOI 10.1007/978-3-642-19193-0_14, © Springer-Verlag Berlin Heidelberg 2011

325

326

14 Seekda: The Business Point of View

Fig. 14.1 The Register, Find
and Bind paradigm

• There are still no effective means of ﬁnding services over the Internet—existing
search engines are aimed at exploiting textual descriptions in Web pages which
are not available for services.

• Services are not transparent, and semi-formal or formal descriptions are not avail-

able for them.

• Combinations of services that fulﬁll more complicated requirements of busi-

nesses are not available.

• In most of the cases, data models underlying the service descriptions do not

match, and transformation between such data models is required.

• Service Level Agreements (SLA) have to be taken into account and this is tradi-

tionally a manual task.

All these aspects pose severe obstacles in creating a true Web of services and
hamper interoperability thereof. The mission of seekda is to ease the search, inter-
operability and bundling of services and thus achieve a true Web of services. seekda
provides a dedicated Web services search engine, featuring monitoring and invoca-
tion facilities. Interoperability and bundling of services are controlled by a Bundle
Conﬁgurator and Assistant tool designed to semi-automatically assist the creation
of service bundles.

In this chapter, we describe how these technologies are developed and illustrate
their beneﬁts. In Sect. 14.2, we describe the technologies employed by seekda to
address the above problems; in Sect. 14.3, we show the application of these tech-
nologies by one of the seekda products.

14.2 Technical Solution

Searching and discovering services is the ﬁrst step towards bundling and using
services. This section describes how seekda, through the use of a search engine
for services, eases the process of ﬁnding, monitoring and also using services over
the Internet. To enable such a search engine, two basic components are needed: a
crawler to discover, classify and index services [8] and a portal that enables end-
users to search for these services.1 Section 14.2.1 describes the crawler, followed

1http://webservices.seekda.com.

14.2 Technical Solution

327

by Sect. 14.2.2 which describes the search portal. To enable the combination of ser-
vices together (called service bundles), seekda provides a Bundle Conﬁgurator and
Assistant tool—this is described in Sect. 14.2.3.

14.2.1 Crawler

The main purpose of the crawler is to crawl the Web in order to ﬁnd, classify and
index services. In this section, we describe the technologies employed by this com-
ponent in order to achieve these functions. Traditionally, searching for services
requires queering on speciﬁc platforms such as StrikeIron or ProgrammableWeb.
However, these platforms require service providers to manually register their ser-
vices in order for them to be found by requesters. This approach does not scale and
a more automated approach is required. Another approach is to provide full seman-
tic descriptions for services and discover them using complex reasoning tasks. The
drawback of this approach is that in the current state of the Web and technologies,
very little semantic annotations for services are available. Furthermore, manually
annotating such services is close to impossible and there currently exist no tools
that automatically extract semantic information.

The crawler developed at seekda detects services over the Web and classiﬁes
them in an internal ontology that is maintained by seekda. Discovered services can
then be annotated with semantic descriptions. The aim is to detect as many public
services as possible. To achieve this goal, the crawler is focused on both WSDL-
based and RESTful services. The search is not just restricted to pure technical ser-
vice descriptions but also encompasses information surrounding the service, for ex-
ample, HTML documents that talk about the services. This information will help in
a two-fold way: to discover the actual service (and to automatically classify it) and
to further annotate the service (given that the extra information about the service
is available). The semantic information is then used by the front-end search engine
that seekda also develops and provides to users (more in Sect. 14.2.2).

The crawler is based on the open source Internet crawler Heritrix2 and it is de-
signed to produce snapshots of a large part of the Internet. There are some default
components and also a processor chain in this system that allow different crawl
conﬁgurations. The processor chain is extended by new processors in order to focus
the crawl on services over the Web, retrieve the related documents and store the
metadata in an RDF store.

A high level overview of the crawling components is given in Fig. 14.2. The
crawler stores fetched documents—including service descriptions—in the Crawler
Repository which contains a set of ARC ﬁles, an RDF store and the Dragon registry.
The crawler data API is an interface that can be used by other components in order
to access the data stored in the crawler repository. The descriptions that are fetched
are compressed and stored in ARC format (a ﬁle format for compressed ﬁles) and

2http://crawler.archive.org.

328

14 Seekda: The Business Point of View

Fig. 14.2 High level
overview of the crawling
components and their layout

the metadata is stored in an RDF store. The Dragon registry is used to index WSDL
ﬁles that are compressed in the ARC ﬁles.

Figure 14.3 shows how URIs are handled by the crawler. The starting point is a
set of URIs, which is called a seed. The Frontier is responsible for determining the
next URI to be crawled. It hands over the URI to a worker thread which executes
a set of processors on this URI. Processors are responsible for enforcing precondi-
tions, fetching the content, extracting links and writing documents to the ﬁle system.
Fetched documents are ﬁrst normalized and then written to ﬁles in the ARC format.
All metadata which has been generated by different processors is sent in the form of
RDF triples to an RDF store. Every extracted link gets a cost assigned, which is done
by one of the non-default Web service speciﬁc processors. This is done for keeping
the crawl focused, as links with a lower cost will be preferred in the queue. The
crawl URI—which now includes the extracted links with the cost assignment—is
returned to the Frontier which adds the links to the Frontier queues.

As described earlier, the crawler can be conﬁgured for speciﬁc needs and also
uses ontologies in the background for classifying the services that are found. In
Sect. 14.2.1.1, the conﬁguration options are described followed by the metadata
information in Sect. 14.2.1.2.

14.2 Technical Solution

329

Fig. 14.3 Architecture of the crawler

14.2.1.1 Crawl Conﬁguration

A crawl conﬁguration consists of hierarchical structured modules and its individual
settings. Figure 14.4 shows the Web interface for deﬁning these settings, speciﬁcally
it shows settings for the module which is responsible for fetching content via HTTP.
We will now describe a simple conﬁguration setup for the crawler. The user sup-
plies some metadata about the crawl, like a description and information about the
operator of the crawl. In addition, a Web crawler should respect other server oper-
ators and follow the rules speciﬁed in robot ﬁles as much as possible. The rules in
the robot exclusion standard specify which user agents are allowed to access which
parts of a Web site. For this reason, the crawl operator speciﬁes how the crawler
should deal with those ﬁles, where the possibilities are to obey the relevant direc-
tives, namely, to completely ignore them or to obey only the most liberal restrictions
available. A custom set of directives can also be provided for speciﬁc hosts.

During crawling, events are logged so that results are understood and conﬁgu-
ration ﬂaws detected. These events include URIs that are handled at a particular
point in time, used system resources and runtime errors. This is all taken care by the
logger module.

The starting point of a crawler is the so-called seed, containing a set of URIs.
These URIs are crawled ﬁrst and depending on the existence and conﬁguration of
other modules, the links on these sites will be added to a queue for further process-
ing. The rules for following such links are called scope rules. Since the crawler is

330

14 Seekda: The Business Point of View

Fig. 14.4 Conﬁguration interface of the crawler

focused exclusively on services, content that is not relevant is excluded (such as
images, audio, movies, etc.).

Different ﬁlter implementations are available in order to exclude processed URIs.
The nature of these implementations is determined by whether processed URIs are
managed in-memory or on disk. For example, the BDB ﬁlter uses a BerkeleyDB
JE database to hold its records of known hosts (queues), while the Bloom ﬁlter
works in-memory over hashing functions. The BDB implementation can be used
for smaller crawls with less than ten million URIs. When the number of URIs gets

14.2 Technical Solution

331

higher, the performance decreases and the Bloom ﬁlter is the best choice. This ﬁlter
demands, however, substantial memory.

The run of a crawl is controlled by the crawl controller. This component can be

conﬁgured with the following parameters:

• Maximum response time when crawling over a URI.
• Number of attempts the crawler makes to get the contents of a URI.
• Uptime of the crawler.
• How many working threads should be created.

The main part of the crawl conﬁguration is the list of processors (i.e., the num-
ber of working threads). All URIs that are in the scope are handled by each of the
processor on this list. PDF ﬁles are converted to HTML in order to ease further
processing and an HTML extractor is used to get new URIs from the translated
document. Information about the structure of the document can also be extracted.
This information is used by other processors to take decisions (for example, about
how likely it is that a service is available). Other types of URI extractors are used
to extract links from other formats such as XML, Javascript and ﬂash/shockwave
ﬁles. Custom processors generate a link graph which describes how links are con-
nected together from a source to the next. All these documents are stored as ARC
ﬁles. WSDL documents, however, are handled by a different speciﬁc processor. All
processors can add RDF triples—which are collected by another processor in the
list—and commit these triples to an RDF store. Such statements use concepts from
the speciﬁc ontologies, described in Sect. 14.2.1.2.

Given these pieces of information about the document and the outgoing links, a
cost assignment for all the new URIs is made. As mentioned, URIs with the lowest
cost will be processed ﬁrst. The value of this assignment depends on the nature
of the crawl. For example, when crawling for Web services, the value depends on
keywords.

The described conﬁgurations are stored as proﬁles and can be reconﬁgured for
every single job. Each crawl produces speciﬁc types of outputs. When crawling
for WSDL descriptions, two types of archives are produced: one containing all the
WSDL ﬁles and another containing the related documents. When crawling for REST
services, two other types of archives are produced: one containing the related doc-
uments and another containing the metadata (in the form of RDF triples) that is
extracted from the service.

The problem here is what related exactly means. The approach is to use the link
graph as the basis for this decision: all documents that have a direct link to the
WSDL are considered to be related to the service. Such link connections are either
outgoing links, i.e., links from the WSDL to other document, or incoming links,
i.e., links that lead from other documents to the WSDL. Another approach is to use
vector similarities. This is done by comparing the term vectors of WSDL ﬁles with
the term vectors of web documents gathered from the same domain of the WSDL
ﬁles. This might help, for example, in ﬁnding pages on a service provider’s site that
talk about the service without being directly interlinked with it.

332

14 Seekda: The Business Point of View

Fig. 14.5 Crawler ontology

The related documents assemble information in different formats, such as HTML
pages, text ﬁles, PDF ﬁles. All the documents are normalized, i.e., they are all en-
coded in UTF8; PDF ﬁles are transformed to HTML, and HTML ﬁles are cleaned
from unnecessary markup and stripped to avoid lengthy pages. Together with the
two archive types, an index is delivered. This index maps services to WSDL de-
scriptions and to related information. Furthermore, it allows random access to the
archive data by indicating the archive number and offset of all documents. Along
with the textual representation of the documents, some other information about its
retrieval is stored. This includes the URL, the date of archiving, the content-type
and the offset of the record in the ARC ﬁle. Other information (such as the service
provider data) which is extracted from the WSDL ﬁle, is then represented as RDF
triples based on the ontologies described in Sect. 14.2.1.2.

14.2.1.2 Metadata

All information about the services, such as their WSDL description(s), their related
documents, their provider, their operations, etc., is structured according to a generic
Service Ontology (Fig. 14.5). This ontology has been developed in the scope of the
European project Service-Finder3 which is building a platform for Web service dis-
covery embedded in a Web 2.0 environment. The Service-Finder Service Ontology4
is publicly available under the Creative Commons Attribution-Noncommercial-
ShareAlike 3.0 Unported License. This ontology has been extended to support sup-
plementary information coming from the crawler. An additional feature is the clas-
siﬁcation of documents. Each document is tested for containment in a speciﬁc class
and a score is assigned. This score determines how certain the containment is.

3http://www.service-ﬁnder.eu.
4http://www.service-ﬁnder.eu/ontologies/sfo.rdfs.

14.2 Technical Solution

14.2.2 Search Engine

333

The crawling information is used by the front-end service search engine portal
which is also developed and maintained by seekda. Services that are indexed also
have their behavior monitored; such information can also be accessed through the
search engine. Furthermore, services can be directly invoked through this search en-
gine. This section describes such features and gives a brief walk-through on how to
use the search engine.

Figure 14.6 shows the portal for the Web services search engine provided at
http://webservices.seekda.com. The interface resembles that of a normal search en-
gine but the layout of the search results is slightly different and constructed in a way
to show a high level overview of the services’ characteristics. Figure 14.7 shows a
snapshot of the results obtained when searching using the keyword SMS. Results
can be sorted by other criteria, such as provider and country. For each result entry,
the following information is provided:
• Name of the service.
• Provider of the service.
• Country where the service is available.
• A short description of the service.
• Tags associated with the service.

When selecting a speciﬁc service, more information is given, which includes
the location of the WSDL ﬁle (if applicable), the availability of the service (in a
percentage form) and the user rating for the service. Users can also write their own
textual descriptions to the service. These aspects are shown in Fig. 14.8.

When clicking on the Availability tab in Fig.14.8, a graph similar to that shown
in Fig. 14.9 is observed. What the graph shows is a more detailed description of the
availability of the service. Among other things, the following are shown:
• Average/connect time in milliseconds until connection with the service could be

established.

• Average/response time in milliseconds until response was completely received.
• Connect errors and timeouts.
• Read errors and timeouts.

As described earlier, services can also be directly invoked from the search engine
interface. When clicking on Use Now, more details about the available operations
are made available. When clicking on one of the operations, the user is presented
with a form with input ﬁelds. These ﬁelds are actual parameters that are given to
the operation (Fig. 14.10, left). Once invoked, the result of the operation is again
presented to the user (Fig.14.10, right).

14.2.3 Bundle Conﬁgurator and Assistant

As described earlier, one of the missions of seekda is to ease the creation of service
bundles. This is done through the adaptation of existing technologies and through
the use of intelligent problem solving methods and leveraging between static and

334

14 Seekda: The Business Point of View

l
a
t
r
o
p

e
n
i
g
n
e
h
c
r
a
e
s

e
c
i
v
r
e
S

6
.
4
1

.
g
i
F

14.2 Technical Solution

335

Fig. 14.7 Example of search results

dynamic composition of services. At the static level, widely known notations (such
as BPMN [7] and BPEL [1]) are adapted; at the dynamic level, seekda develops and
implements composition algorithms inspired by the parametric design methodol-
ogy [2, 5]. The bundling solution (called a Service Bundler) is characterized by dy-
namic discovery and binding of third-party Web Services. As new services emerge,
consumption criteria for the existing ones change, and services already used can be

336

14 Seekda: The Business Point of View

Fig. 14.8 An example of a selected service from the search results

disposed of. By reconﬁguration, the new criteria and constraints are met and new
services are discovered and used.

The tool responsible for this is called the Bundle Conﬁgurator and Assistant and
adapts a graphical process notation and plugs in with the parameter and constraint
language. The graphical notation is simple enough to be used by business design-
ers, but it also allows for the ability to express richer functionalities for product
engineers. With respect to task fulﬁllment in the service bundles, current industry
practices rely on keyword-based (manual) searching for available services from a
given pool. Through the use of a parametric design methodology, the tool assists the
designer to ﬁnd adequate services that fulﬁll particular tasks given a speciﬁc set of
parameters. This dramatically reduces the effort required to create service bundles,
and consequently reduces cost and increases efﬁciency of manpower.

One of the main advantages of a template based approach is reusability [4, 6].
Templates are stored and reused in similar domains. The changes for templates
within the same domain are generally minimal, and in many cases this boils down to
different settings for parameters and peculiarities for the speciﬁc context in which
the process has to be deployed. Not only does the provider of the service platform
beneﬁt from this (therefore, seekda itself) but so does the client since skeletons of
processes (in the form of templates) are readily available and only need to be tailored
for speciﬁc needs. Again, this results in less effort, and consequently, in a decreased
burden of cost. Furthermore, the tool itself is generic enough to handle different

14.2 Technical Solution

337

Fig. 14.9 Availability of a service in graphical form

kinds of scenarios—beyond e-Tourism, further application of these methodologies
in the area of e-Conference and e-Messaging are envisioned. This is different from
current approaches in the industry where tools usually are tailored for speciﬁc do-
mains. All-in-all, a high degree of ﬂexibility is expected to be achieved by making
the generation of service bundles efﬁcient.

Considering the template based approach, a stepwise approach for creating ser-

vice bundles is taken. These phases are as follows:

1. Template Design
2. Template Reﬁnement
3. Enactment
4. Execution

Figure 14.11 shows a graphical representation of the different service bundling
phases. The process starts with the Template Design phase during which the Busi-
ness Person identiﬁes the main components needed to perform a particular task.
Along with the main components of the bundle, parameters must be identiﬁed and
properly deﬁned. Various individuals in the company have access to different types

338

14 Seekda: The Business Point of View

)
t
h
g
i
r
(

n
o
i
t
a
r
e
p
o
e
h
t

f
o
t
l
u
s
e
r

d
n
a

)
t
f
e
l
(

n
o
i
t
a
r
e
p
o
e
c
i
v
r
e
s

a

g
n
i
k
o
v
n
I

0
1
.
4
1

.
g
i
F

14.2 Technical Solution

339

s
e
c
i
v
r
e
s

f
o

g
n
i
l
d
n
u
b

e
h
t

f
o
s
e
s
a
h
P

1
1
.
4
1

.
g
i
F

340

14 Seekda: The Business Point of View

of parameters. For an e-Tourism process (described in more detail later in this sec-
tion), we require publishing information about availability of rooms in a hotel across
several booking channels. The business person is interested in deﬁning with which
channels this hotel should be registered, which is not really the case for the tech-
nical (or IT) person. The system therefore also deﬁnes access rights at the level of
categories of parameters which can be edited when creating templates.

The following is the Template Reﬁnement step. During this phase, the template
is further reﬁned with more technical details—these usually must be edited by an
IT person. Such details include the deﬁnition of speciﬁc related parameters to allow
for satisfactory execution of the bundle (for example, fault handling operations).
Speciﬁc types of parameters—accessible by a technical person—are also further
deﬁned during this phase.

The Enactment Phase is at the heart of the whole bundle creation process, during
which templates are fulﬁlled with actual services. Apart from identifying the re-
quired services that satisfy the speciﬁed parameters, the appropriate message map-
pings must be identiﬁed together with routings for these messages through the dif-
ferent control constructs of the process. Another important aspect is the resolution
of violated parameters. Typically, a violation of a parameter does not necessarily
imply that the potential service is completely neglected, but that there might rather
be a speciﬁc action that can be done on the data to make it acceptable by the service.
In an e-Tourism scenario, a speciﬁc channel may require that a picture of the hotel
is of some particular size. If the size is greater than that required, a possible action
can be to crop the picture appropriately—this can also be done by a speciﬁc service
available on the Web.

Finally, the last step is the Execution Phase. This phase takes the concrete in-
stantiated bundle (in the form of some speciﬁc execution language like BPEL) and
executes it.

Before looking into the details of the Bundle Conﬁgurator and Assistant, a few
words need to be said on mediation. As described earlier, current seekda products
tackle mainly an e-Tourism scenario (more in Sect. 14.3). In this setting, seekda
acts as a broker between the hoteliers and the advertisement and search services (for
example, Expedia). Service data models vary, consequently mediation and trans-
formation between such data models have to be catered for. Figure 14.12 gives an
overview of how mediation is approached in seekda.

The datamodel used by seekda (and its products) is OTA—Open Travel Al-
liance.5 OTA deﬁnes a schema that describes elements in the traveling domain, such
as hotels, ﬂights and tickets. With this schema as the underlying datamodel for the
conﬁgurator tool, the datamodels of the services must be mapped to it. Therefore, as
a ﬁrst step, a domain expert must map the OTA elements to target channel services
(for example, Expedia) and store these mappings. When a hotelier would like to
publish the service on different advertising platforms, all the hotelier needs to do is
to provide a mapping from its data model to OTA—the rest is taken care of by the
bundle conﬁgurator (or other tools). At runtime, the incoming message is therefore

5http://www.opentravel.org.

14.2 Technical Solution

341

e
r
u
t
c
e
t
i
h
c
r
a
n
o
i
t
a
i
d
e
M

2
1
.
4
1

.
g
i
F

342

14 Seekda: The Business Point of View

transformed to OTA which, in turn, is transformed to the data model of each speciﬁc
advertising platform (depending upon where the hotelier wants to make the adver-
tisement). In terms of architecture, the key idea here is to store the mappings and
reuse them. Furthermore, when a new Hotelier asks for such a similar service, only
one mapping is needed. Business-wise, this reduces the costs for hoteliers, speeds
up advertisement and updating of room availability, and makes it easier to make use
of more advertising services. More about this is discussed in Sect. 14.3.

The main components of the Bundle Conﬁgurator and Assistant tool are illus-
trated in Fig. 14.13. The Conﬁgurator comprises two main components, namely the
Graphical Interface and the Enactment Engine. The component has access to the
Template, Message Mappings and seekda Service repositories.

The Graphical Interface is the main entry point for the creation of templates. The
Template Editor enables graphically deﬁning a classical process (using the Process
Editor) and additionally specifying parameters that are required to be fulﬁlled by the
desired services (through the Parameter Editor). The former typically resembles a
normal workﬂow editor, with additional elements required for the system’s needs;
the latter allows the creation of parameters based on a speciﬁc language, allowing
also actions to be taken in case of parameter violations.

The Enactment Engine consists of the Composer and the Message Mapping
Finder. The Composer is responsible for ﬁnding appropriate services that match
the requested parameters; this is done through the Parameter Resolution compo-
nent. If services are required to be connected with one another, then the Message
Router comes into play to route the appropriate messages between them through the
required control ﬂow constructs. The Message Mapping Finder is used to identify
the required mappings between the different types of the schema of the services.

14.3 Illustration by a Larger Example

In this section, we describe one of the main products provided by seekda, namely
seekda! connect. As brieﬂy pointed out in Sect. 14.2.3, the core idea is for seekda
to act as intermediary between a hotelier and an advertising service. The domain
is therefore the same, but each hotelier has speciﬁc requirements and constraints
which determine, amongst other things, which advertising channels are to be used.
Figure 14.14 shows an overview of the basic idea for seekda! connect. Consider a
hotelier who would like to advertise the hotel on different channels. Traditionally,
the hotelier is required to go and connect with every distributing channel in order to
advertise the hotel. Hence, a lot of effort is required:
• A translation between the data model of the hotelier and the data model of every

channel is needed.

• Given a change in the hotelier’s data model, every translation has to be changed

(consequently, this approach is not so scalable).

• Different service level agreements must be maintained.
• More costs are incurred to maintain these connections between different channels

leading to more drawbacks:

14.3

Illustration by a Larger Example

343

l
o
o
t

t
n
a
t
s
i
s
s
a

d
n
a

r
o
t
a
r
u
g
ﬁ
n
o
c

e
l
d
n
u
b

e
h
t

f
o
e
r
u
t
c
e
t
i
h
c
r
a

l
e
v
e
l
h
g
i
H

3
1
.
4
1

.
g
i
F

344

14 Seekda: The Business Point of View

Fig. 14.14 seekda! connect overview

– Due to the substantial degree of costs, it is very likely that the number of dis-
tributing channels is low, and consequently the hotel is less reachable by end
users.

– Due to the higher costs and less reachability by end users (and consequently,

fewer customers), the proﬁt margin is lower.

seekda! connect aims at overcoming the above bottlenecks. A hotelier is no
longer required to go to every distributing channel, but rather uses seekda to con-
nect to them. The system therefore serves as a broker between the hotelier and the
different distributing channels. Different distributing channels—and their associated
options—are provided to the hotelier in one single stop. The system uses OTA as the
underlying data model, and consequently, only one mapping between the hotelier’s
data model and OTA is needed. The rest of the mappings are provided by seekda.
Furthermore, hoteliers are no longer required to go through every channel and com-
pare options therein. Rather, it is all conveniently presented and compared—the
hotelier simply chooses which channels are desired, in a similar fashion as that of
using a shopping cart on a typical e-Commerce Web site. During this process, the
system—thanks to intelligent methods described in previous sections—assists the
hotelier in conﬁguring the components of the advertising process and the channels.
Given this approach, the costs for the hotelier are drastically reduced, a higher
degree of distribution over the channels is achieved, and consequently, more end-
users can be reached. This is also beneﬁcial for the distribution channels themselves
as more hoteliers are attracted to use their services. We will now go step by step
through this system and point out some of the technical peculiarities in the process.
We will describe the setup of a hotel called Hotel Erfolg. Initially, the hotelier logs in
to seekda! connect and sets up the general properties of the hotel (Fig. 14.15). There
are various other aspects that can be described at this stage, for example, amenities,
rooms, policies, and seasons of operation. We will look at the rooms setup.

First, the rooms are created and given an identiﬁer. After this, their particular

features are described (Fig. 14.16).

14.3

Illustration by a Larger Example

345

Fig. 14.15 General properties for Hotel Erfolg

Following the room creation step is the setup of the rates. This is done through
a calendar system. Amongst the properties are the setup of rates (for each possible
number of guests in the room), adult and child pricing, as well as minimum and
maximum number of guests (Fig. 14.17). Note that all these conﬁguration param-
eters are possible input to the bundle conﬁgurator as described previously—an end
user may use these types of conﬁgurations to ﬁnd speciﬁc hotel stays.

In the availability view, the hotelier is able to access the rooms that are available
in the hotel (Fig. 14.18). Note that these are automatically updated with reservations
and cancelations.

Note that all of the information shown above is stored and described in XML
using the OTA data model. Furthermore, all of this information can be mediated and
exported to different distributing channels. This is one of the core parts of seekda!
connect, integrating with other distributing channel systems such as the hotelier
who does not have to go through the burden to replicate all the information on
different channels; this is done automatically by the system. In our particular exam-
ple, Expedia and Hotel.de are two distributed channels that the hotelier has enabled
(Fig. 14.19).

Having this data setup, normal end users can now simply look for rooms either
on the distributing channels, or through the hotelier’s Web site. Figure 14.20 shows
how the search widget of the system is embedded within the hotel’s Web site. From

346

14 Seekda: The Business Point of View

Fig. 14.16 An example of a room setup

Fig. 14.17 Rates setup for a room in Hotel Erfolg

14.3

Illustration by a Larger Example

347

Fig. 14.18 Availabilities view for a room

Fig. 14.19 Enabled channels for Hotel Erfolg

348

14 Seekda: The Business Point of View

Fig. 14.20 Embedded seekda! connect search widget on Hotel Erfolg

that point on, the end user simply selects an available room in a standard fashion
(Fig. 14.21).

Our future work is aimed towards more ﬂexibility in using the aforementioned
techniques. Our vision is depicted in Fig. 14.22 which shows how an e-Tourism
template is constructed using seekda! connect. The example already contains a few
of the parameters and constraints that could be part of this template. These may
include:

• Setting variable number of rooms to advertise could depend on the channel.
• Advertising availability of room categories might depend on the speciﬁc channel.
• Dealing with proactive notiﬁcations when a room is booked.
• Handling faults.
• Transforming data.

At the template level, the process is very simple. As a start, a Product Engineer
describes the process in its primitive form. For example, the start and end nodes,
and the checking and advertise tasks, as well as additional services (booking the
car, booking the skip pass, paying for a service). These tasks provide a very high
level description of what the process should do. Additional constraints may be spec-
iﬁed by the product engineer or by other entities. For example, a process engineer
speciﬁes that these actions must be performed in an authorized way. Next, a cus-
tomer (a hotelier, in this case) may further specify constraints and other options.
This idea will be developed in the form of a dynamic shop, whereby third party ser-
vice providers will also be able to register with the system and have their services
conﬁgured to work with speciﬁc hotels.

14.4 Summary

349

Fig. 14.21 A search for a hotel stay using the embedded widget on Hotel Erfolg

14.4 Summary

In this chapter, we described the technologies employed by seekda to enable a true
Web of services. As a ﬁrst step, seekda provides a crawler that looks for services
(both WSDL and REST), classiﬁes them into an ontology, creates RDF metadata
triples (if possible) and indexes them. Next, a search portal enables, to look for such
services, to view monitoring data related to the services, and possibly invoke them.
Finally, a bundle conﬁgurator tool enables the creation and mediation of service
bundles. Such bundles are conﬁgured in a stepwise manner and automatically en-
acted to create an executable process that can be deployed and used by a third-party.
These technologies have been illustrated by an example from the seekda! connect
e-Tourism product.

350

14 Seekda: The Business Point of View

n
o
i
t
i
s
o
p
m
o
c
d
e
s
a
b
-
e
t
a
l
p
m
e
t

t
c
e
n
n
o
c

!
a
d
k
e
e
s

2
2
.
4
1

.
g
i
F

14.5 Exercises

14.5 Exercises

351

Exercise 1 Describe the Register, Find and Bind paradigm and the entities in-
volved.

Exercise 2 Give at least three bottlenecks that are hampering a true Web of ser-
vices in the current Internet.

Exercise 3 List and brieﬂy describe the 3 main components that are provided by
seekda to ease the ﬁnd and composition of services.

Exercise 4 Describe the Crawling process.

Exercise 5 Apart from searching, what are the two other features provided by the
seekda Web service search engine?

Exercise 6 Which methodology does the service bundler use for composition?

Exercise 7 List and describe the four phases for creating and using service bun-
dles.

Exercise 8 List at least two advantages created by the mediation architecture and
the seekda! connect product.

References

1. Alves, A., Arkin, A., Askary, S., Barreto, C., Bloch, B., Curbera, F., Ford, M., Goland,
Y., Guzar, A., Kartha, N., Liu, C.K., Khalaf, R., König, D., Marin, M., Mehta, V., Thatte,
S., van der Rijn, D., Yendluri, P., Yiu, A.: Web Services Business Process Execution Lan-
guage, Version 2.0 edn. OASIS (2006). http://www.ibm.com/developerworks/webservices/
library/ws-bpel/. OASIS. Public Review Draft, http://docs.oasis-open.org/wsbpel/2.0/

2. Fensel, D.: Problem-solving Methods: Understanding, Description, Development, and Reuse.

Lecture Notes in Computer Science, vol. 1791. Springer, Berlin (2000)

3. MacKennzie, C.M., Laskey, K., McCabe, F., Brown, P.F., Metz, R.: Reference model for service

oriented architecture 1.0. Tech. rep., OASIS (2006)

4. Mandell, D., McIlraith, S.: Adapting BPEL4WS for the Semantic Web: the bottom-up approach

to web service interoperation. In: Proc. of ISWC’03 (2003)

5. Motta, E.: Reusable Components for Knowledge Modelling: Case Studies in Parametric Design

Problem Solving. IOS Press, Amsterdam (1999)

6. Narayanan, S., McIlraith, S.: Simulation, Veriﬁcation and automated composition of Web ser-

vices. In: Proc. WWW’02 (2002)

7. OMG: Business Process Modeling Notation—Bpmn 1.0. http://www.bpmn.org/. Final Adopted

Speciﬁcation, 6 February 2006

8. Steinmetz, N., Lausen, H., Brunner, M.: Web service search on a large scale. In: Proceedings of
the 7th International Joint Conference on Service Oriented Computing (ICSOC 2009) (2009)

Index

A
A2A Integration, 174
Abstract State Machines (ASM), 115, 134,

Communication, 173
Composition, 163, 173, 180, 238
Customer Relationship Management (CRM),

179, 205

200, 202

Adaptation, 163, 173
Adoption, 238
Advanced Research Projects Agency (ARPA),

11

American Standard Code for Information

Interchange (ASCII), 90

Anonymous identiﬁer, 137
Application Programming Interface (API), 39,

48, 165

Asynchronous JavaScript and XML (AJAX),

77, 78
Atom Entry Document, 78
Atom Feed Document, 78
Atom Publishing Protocol (AtomPub), 78, 79
Atom Syndication Format, 78
Axiom, 113

B
B2B, 16, 20, 37, 55
B2B Integration, 174, 200
B2C, 16, 20, 37
Blogosphere, 5
Business Process Execution Language
(BPEL), 39, 164, 191, 269
Business Process Execution Language for Web
Services (BPEL4WS), 167

C
Cascading Style Sheets (CSS), 77
Choreography, 172
in IRS, 273, 275

D
DARPA Agent Markup Language (DAML),

120

Datalog, 135, 153
DBpedia, 99
Delicious, 88
Description Logic Programs (DLP), 135
Description Logics (DLs), 97, 132–135, 141,

144, 158, 223, 261

SHIQ, 135

Discovery, 163, 172, 176, 185, 207, 238

in IRSIII, 273

Document Object Model (DOM), 74, 77
Document Type Deﬁnition (DTD), 91, 101
Dublin Core (DC), 109, 110, 138

E
E-Commerce (Electronic Commerce), 16, 19,

20, 37
E-Service, 26–34
E-Tourism (Electronic Tourism), 119
EBusiness, 5
EbXML, 50, 53, 59
Registry, 54, 55
Registry Information Model (RIM), 54
Registry Services and Protocols (RS), 54

Electronic Data Interchange (EDI), 16
Electronic Funds Transfer (EFT), 16
Enterprise Application Integration (EAI), 37,

Choreography Engine, 179, 275
Closed-World Assumption (CWA), 132

174

Entity-Relationship (ER), 98

D. Fensel et al., Semantic Web Services,
DOI 10.1007/978-3-642-19193-0, © Springer-Verlag Berlin Heidelberg 2011

353

354

Execution Management, 172
Execution Semantics, 192
achieveGoal, 198
getWebServices, 196
invokeWebService, 196

Extensible HyperText Markup Language

(XHTML), 77

Extensible Markup Language (XML), 39, 43,

45, 51, 54, 67, 68, 70–73, 76–78,
83, 89, 91, 92, 94–96, 101, 108,
119, 135–137, 164, 168

External Communications Manager, 182

F
F-Logic, 135
Facebook, 88
Fault Handling, 173
File Transfer Protocol (FTP), 11
First Order Logic (FOL), 132
Flickr, 72, 80
Future Internet, 3, 238

G
Geonames, 99
Goal, 179, 261, 272, 273
Google, 88
GRDDL, 93
Grounding, 173

H
Horn Logic (HL), 135, 144
HRESTS, 6, 118, 119
HyperText Markup Language (HTML), 12, 72,

76, 78, 88, 99

Hypertext Transfer Protocol (HTTP), 12, 39,
44, 45, 47, 57, 68–70, 78, 88, 164

I
Internationalized Resource Identiﬁer (IRI),

110, 136, 145

Compact IRI, 136

Internet Information Services (IIS), 34
Internet Reasoning Service, 270

Architecture, 271
IRS-III, 271
Invocation, 163
IRIS, 153

Index

K
KAON2, 153

L
Linda, 221, 223, 225, 227, 228, 242
Linked Data, 5, 98, 99, 101
Linked Open Data (LOD), 99, 101
LinkedIn, 88
Logic Programming (LP), 133–135, 142, 143,

158

M
Mediation, 109, 173

Data Mediation, 164, 177, 185, 208, 273
Process Mediation, 164, 186, 208, 209, 273

Mediator, 139

GGMediator, 117, 120, 124, 275
OOMediator, 117, 124, 273
WGMediator, 117, 124, 150, 273, 275
WWMediator, 118, 124

Message Exchange Pattern (MEP), 43
Meta-Object Facility (MOF), 109–112, 272
METEOR-S, 263
MWSAF, 264
MWSCF, 268
MWSDI, 268
WSDL-S, 264

MicroWSMO, 5, 6, 118, 119, 155
MINS, 153
Mobile Web, 3
Monitoring, 163, 173

N
Negotiation, 163
Netscape, 88

O
OCML, 271
Ontology, 96, 108–110, 112, 116, 117
Ontology Mapping, 206
Open World Assumption (OWA), 132, 133
Orchestration, 115, 179, 204, 275

in IRS, 275

Orchestration Engine, 179
Order Management System (OMS), 200, 202,

209

OWL-S, 5, 6, 109

Process Model, 262

J
JavaScript, 73–75, 77, 78, 83, 84
JavaScript Object Notation (JSON), 68, 72–75,

77, 81, 83

P
Partner Interface Processes (PIPs), 200
PELLET, 153

Index

355

Q
Qualiﬁed Name (QName), 136, 137
Quality of Services (QoS), 204

R
Ranking, 177, 238

Ranking Interface, 177

RDF N-Triple, 93
RDF Notation 3 (N3), 93
RDF Schema, 94–96, 101, 119, 134, 135, 138,

139, 223

RDF Turtle, 93
RDF/XML serialization, 93
RDFa, 6, 93
Reasoner, 185
Reasoning, 168, 173, 238
Reiﬁcation, 93
Resource Description Framework (RDF),

92–96, 98, 99, 101, 135, 136, 142,
221, 223, 225, 227, 229–231, 234,
236, 237, 244–246

REST, 6, 68, 69
RESTful Service, 68–70, 72, 77–80, 83, 84,

118, 220, 240

RosettaNet, 179, 200, 209
Rule Interchange Format (RIF), 95, 98, 101,

155, 158

RIF-BLD, 98
RIF-Core, 98
RIF-FLD, 98
RIF-PRD, 98

S
SA-REST, 6
Secure Sockets Layer (SSL), 34
Security, 172
Sedvice, 242
Selection, 207, 238
in IRSIII, 273

Semantic Annotations for WSDL (SAWSDL),
5, 6, 118, 119, 263, 267
Semantic Execution Environment (SEE), 231
Semantic Web, 6, 90, 91, 94–96, 98, 101, 108,

109, 133, 220, 222, 223, 225, 242

Semantic Web Layer Cake, 90, 101
Semantic Web Rule Language (SWRL), 133
Semantic Web Services (SWS), 5–7, 107–110,

118, 119, 124, 127, 128, 131, 153,
163, 231, 241, 243, 247

Semantically Enabled Service Oriented

Architecture (SESA), 128, 163, 175,
200, 238
Middleware Layer, 172
Base Layer, 173

Broker Layer, 172
Vertical Layer, 172
Problem Solving Layer, 171
Service Providers’ Layer, 173
Service Requesters’ Layer, 172
Stakeholders’ Layer, 171

Service, 26, 41, 109
Service Cloud, 238, 240–242
Service Delivery Platform, 29, 237
Service Level Agreements (SLA), 204
Service Oriented Architecture (SOA), 30, 38,

39, 55, 56, 163, 237, 240, 241

Service Oriented Computing (SOC), 4, 38, 39,

56, 164

Service Science, 25–27, 29, 34, 35
Service Web, 238, 242
SharePoint, 34
Simple API for XML (SAX), 77
Simple Mail Transfer Protocol (SMTP), 47, 57
Simple Object Access Protocol (SOAP), 6, 39,

44–47, 50, 53, 56, 57, 67, 68, 107,
164, 167, 168, 184, 220, 231, 246

SPARQL, 93–96, 101, 227
Standard Generalized Markup Language

(SGML), 76, 91

Storage, 173
SWS Challenge, 200
System Behavior Modeling, 192

T
Transmission Control Protocol/Internet

Protocol (TCP/IP), 11
Triple Space, 220–234, 236–238, 240–242,

244–247
Triples Space, 247
Tuple Space, 190, 220–223

U
Unicode, 90, 91
Uniﬁed Modeling Language (UML), 98, 193

Activity Diagrams, 193

Uniﬁed Service Description Language

(USDL), 6

Uniform Resource Identiﬁer (URI), 12, 13, 67,
68, 70, 88, 91–93, 98, 99, 101, 108,
136, 220, 225

Uniform Resource Locator (URL), 91, 226
Uniform Resource Name (URN), 13, 91
Unique Names Assumption (UNA), 133
Universal Description Discovery and

Integration (UDDI), 42, 47, 48, 56,
57, 67, 107, 267, 268

356

Index

Universal Description Discovery and

Integration (UDDI) Registry, 42, 56,
57

V
Virtual Travel Agency (VTA), 55, 81, 119,

155, 242

Vocabulary of Interlinking Datasets (voiD),

101

W
Web 2.0, 22, 88, 89, 238
Web Application Description Language

(WADL), 68, 70, 71, 81, 83

Web Architecture, 14, 15
Web Ontology Language (OWL), 94–98, 101,

132–135, 138, 141, 153, 158, 223

OWL 2, 97
OWL DL, 97, 135, 139
OWL Full, 97
OWL Lite, 97
OWL2EL, 97
OWL2QL, 97, 98
OWL2RL, 97

Web Science, 9, 10, 22, 25
Web Science Research Initiative (WSRI), 9, 10
Web Service, 5, 6, 37, 38, 40, 41, 45, 51, 55,

56, 67, 68, 107, 109, 131, 134, 179,
220, 221, 225, 231, 238, 240, 241,
272

Web Service Description Language (WSDL),
6, 39, 42, 43, 45, 47, 52, 56, 57, 67,
70, 107, 118, 147, 164, 203

Web Service Description Language (WSLD),

231

Attribute, 139
Axiom, 142
Capability, 142
Concept, 139
Conceptual Syntax, 136
Datatypes, 137
Header, 138
importsOntology, 138, 150
Instance, 141
Logical Expression, 142
Logical Expression Syntax, 136
Message Exchange, 147
Molecule, 143
Prologue, 137
Relation, 141
State Signature, 147
Term, 143
Transition Rule, 147
usesMediator, 139
Variable, 142
WSML-Core, 135, 136, 141, 144, 155
WSML-DL, 135, 136, 141, 144, 155
WSML-Flight, 135, 137, 144
WSML-Full, 135, 144
WSML-Quark, 155
WSML-Rule, 135, 144, 155

Web Service Modeling Ontology (WSML),

237

Web Service Modeling Ontology (WSMO), 5,

6, 108–111, 116, 119, 120, 124,
127, 128, 131–134, 153, 155, 202,
231, 243

Assumption, 146, 150, 151
Capability, 120, 145, 150, 203
Choreography, 115, 147, 151, 179, 204,

Web Service Execution Environment

272

(WSMX), 6, 108, 109, 128, 163,
187, 231, 233, 234, 236, 237,
242–247

Communication and Coordination

Component, 189

Core Component, 187, 234
Grounding Component, 232
Invoker Component, 232
Management Component, 188
Manager Component, 236
Resource Manager Component, 186, 237,

243

Web Service Modeling Framework (WSMF), 6
Web Service Modeling Language (WSML), 6,

108, 119, 128, 133–139, 141, 147,
158, 202, 236

Annotations, 138, 148
Atom, 143

Effect, 146, 150, 151
Goal, 109, 116, 117, 120, 149
Interface, 115, 145, 147, 151
Mediator, 109, 111, 116, 152
Non Functional Properties, 114, 148, 177,

204
Ontology, 139, 142
Orchestration, 147, 208
Postcondition, 146, 150, 151
Precondition, 146, 150
Web Service, 109, 111, 113, 116–118, 120,

145, 146, 149, 152

Web Service Modeling Toolkit (WSMT), 152,

153, 175, 203

Web Services Programming Model, 39, 165
Web Tools Platform (WTP), 153
World Wide Web (WWW), 12, 14, 68, 76, 87,

108, 221, 222, 224

Index

WS-Addressing, 50, 59
WS-Policy, 50–52, 59
WS-Security, 50, 53, 59
WSML2Reasoner, 153
WSMO-Lite, 5, 6, 118, 119, 155
WSMO4J, 185, 186, 243

357

XPath, 94
XQuery, 95, 136
XSL Transformation, 206
XSL Transformations (XSLT), 77, 89

X
XML Schema, 43, 91, 92, 101, 136, 137, 203,

220

Y
YouTube, 88

